-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Introduced workflows, mypy, ruff and pylint
- Workflow that validates that the python apis can be generated * mypy runs after this because it is dependent on generated code - Added ruff configuration * workflow validate formatting and code style - Added missing __init__.py files that are needed by tools in order to derive fqn - Added py.typed * Package maintainers who wish to support type checking of their code MUST add a marker file named py.typed to their package supporting typing - .pylintrc which ignores some more warnings compared to the default settings - Formatted code according to new rules, ignored some warnings
- Loading branch information
1 parent
886e659
commit 467390c
Showing
16 changed files
with
1,005 additions
and
298 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,30 @@ | ||
name: Doc builder and mypy | ||
|
||
on: push | ||
|
||
jobs: | ||
build-docs: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Build docs | ||
env: | ||
NO_TTY: true | ||
run: | | ||
cd python/remotivelabs-broker | ||
./docker-build.sh | ||
- name: Setup Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
architecture: x64 | ||
- name: Install mypy | ||
run: | | ||
pip install mypy | ||
pip install python/remotivelabs-broker | ||
pip install python/remotivelabs-broker[default] | ||
- name: Run mypy | ||
run: | | ||
cd python/remotivelabs-broker | ||
mypy . --explicit-package-bases |
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,39 @@ | ||
name: Code-QA | ||
|
||
on: push | ||
|
||
jobs: | ||
ruff-lint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: chartboost/ruff-action@v1 | ||
|
||
ruff-format: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/checkout@v4 | ||
- uses: chartboost/ruff-action@v1 | ||
with: | ||
src: "." | ||
args: format --check --diff | ||
|
||
pylint: | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
- name: Setup Python | ||
uses: actions/setup-python@v5 | ||
with: | ||
python-version: 3.8 | ||
architecture: x64 | ||
- name: Install pylint | ||
run: | | ||
pip install pylint | ||
pip install python/remotivelabs-broker | ||
pip install python/remotivelabs-broker[default] | ||
- name: Run pylint | ||
run: | | ||
cd python/remotivelabs-broker | ||
pylint **/*.py |
Oops, something went wrong.