Skip to content

Commit

Permalink
chore: Attempt to fix Python linting and testing.
Browse files Browse the repository at this point in the history
  • Loading branch information
natm committed Feb 12, 2024
1 parent 93431ea commit 54ac4bb
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 12 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/python-netbox-plugin-lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r src/requirements.txt
pip install -r src/tests/requirements.txt
pip install .
pip install .[dev]
pip install .[test]
- name: Lint with Ruff
run: |
pip install ruff
ruff --output-format=github diode-netbox-plugin/netbox_diode_plugin/ diode-netbox-plugin/tests/
continue-on-error: true
6 changes: 3 additions & 3 deletions .github/workflows/python-sdk-lint-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,9 @@ jobs:
- name: Install dependencies
run: |
python -m pip install --upgrade pip
pip install -r src/requirements.txt
pip install -r src/tests/requirements.txt
pip install .
pip install .[dev]
pip install .[test]
- name: Run tests with coverage
run: |
Expand All @@ -38,6 +39,5 @@ jobs:

- name: Lint with Ruff
run: |
pip install ruff
ruff --output-format=github diode-sdk-python/netboxlabs/ diode-sdk-python/tests/
continue-on-error: true
8 changes: 6 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,11 @@ coverage.txt
# diode-server
diode-server/build/

# Byte-compiled / optimized / DLL files
# Python
__pycache__/
*.py[cod]
*$py.class
*$py.class
.Python
build/
.eggs/
*.egg-info
4 changes: 2 additions & 2 deletions diode-netbox-plugin/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@ dependencies = [ # Optional
]

[project.optional-dependencies] # Optional
#dev = ["check-manifest"]
#test = ["coverage"]
dev = ["black", "check-manifest", "ruff"]
test = ["coverage"]

[project.urls] # Optional
"Homepage" = "https://netboxlabs.com/"
Expand Down
5 changes: 3 additions & 2 deletions diode-sdk-python/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -29,15 +29,16 @@ dependencies = [ # Optional
]

[project.optional-dependencies] # Optional
#dev = ["check-manifest"]
#test = ["coverage"]
dev = ["black", "check-manifest", "ruff"]
test = ["coverage"]

[project.urls] # Optional
"Homepage" = "https://netboxlabs.com/"

[project.scripts] # Optional

[tool.setuptools]
packages = ["netboxlabs.diode.sdk"]

[build-system]
requires = ["setuptools>=43.0.0", "wheel"]
Expand Down

0 comments on commit 54ac4bb

Please sign in to comment.