-
Notifications
You must be signed in to change notification settings - Fork 150
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add GitHub actions for Python and pre-commit checks for go #1704
Changelog: - [ ] Adds GitHub actions to check the PR for Python code changes See: https://docs.astral.sh/uv/guides/integration/github/ - [ ] Adds pre-commit checks so that go tests pass per commit. - [ ] Configure prettier to ignore .mypy_cache/ - [ ] Fixes formatting for some engdoc
- Loading branch information
Showing
6 changed files
with
63 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,45 @@ | ||
name: Python Checks | ||
|
||
on: | ||
pull_request: | ||
paths: | ||
- 'py/**' | ||
|
||
jobs: | ||
python-checks: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: | ||
- "3.12" | ||
- "3.13" | ||
defaults: | ||
run: | ||
working-directory: py | ||
|
||
steps: | ||
- uses: actions/checkout@v4 | ||
|
||
- name: Pre-requisites | ||
run: bin/setup -a ci | ||
|
||
- name: Install uv and setup Python version | ||
uses: astral-sh/setup-uv@v5 | ||
with: | ||
enable-cache: true | ||
python-version: ${{ matrix.python-version }} | ||
|
||
- name: Format check | ||
run: uv run ruff format --check . | ||
|
||
- name: Lint with ruff | ||
run: uv run ruff check . | ||
|
||
- name: Run tests | ||
run: uv run pytest . | ||
|
||
- name: Build documentation | ||
run: uvx mkdocs build --strict | ||
|
||
- name: Build distributions | ||
run: ./bin/build_dists |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,9 +1,10 @@ | ||
go/ | ||
public/ | ||
.github/ | ||
.mypy_cache/* | ||
.prettierrc.yaml | ||
pnpm-lock.yaml | ||
docs/* | ||
docs-go/* | ||
docs/* | ||
genkit-tools/genkit-schema.json | ||
go/ | ||
pnpm-lock.yaml | ||
public/ | ||
py/* |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -388,9 +388,9 @@ capabilities in code: | |
|
||
=== "Python" | ||
|
||
```python | ||
```python | ||
|
||
``` | ||
``` | ||
|
||
=== "JavaScript" | ||
|
||
|