-
Notifications
You must be signed in to change notification settings - Fork 4
102 separate linting workflow in ci #103
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Changes from all commits
c593091
b4e44c1
b72172c
e9ffbbd
08d2324
f2d3613
5f725f1
fcddb5a
9607277
faf7f0b
e1f9c4f
283e2fc
05dadd2
53d9e9d
51f7a07
9ee816d
273b6e9
ba656f0
2b86808
ef9ca8e
8ffb6eb
2f43ab0
f1114a2
c1a1dca
5bee526
41e61c5
e19327e
6c79703
0cbcaa3
9f3170b
80ffaa5
bf00bd4
41598ef
f67a20d
c7ac744
a0157e6
9301939
aff0251
5c48560
47af75d
bbaa34d
b7d0f7d
26df33e
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,27 @@ | ||
| name: Linting and Formatting | ||
|
|
||
| on: | ||
| pull_request: | ||
|
|
||
| jobs: | ||
| lint: | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v7 | ||
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Install uv | ||
| uses: astral-sh/setup-uv@v7 | ||
| with: | ||
| version: "0.12.0" | ||
|
|
||
| - name: Install package | ||
| run: uv sync --group dev | ||
|
|
||
| - name: Check styling | ||
| run: uv run ruff format --check . | ||
|
|
||
| - name: Check linting | ||
| run: uv run ruff check src/lanfactory |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -19,24 +19,20 @@ jobs: | |
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Setup Python | ||
| uses: actions/setup-python@v6 | ||
| with: | ||
| python-version: ${{ matrix.python-version }} | ||
|
|
||
| - name: Install uv | ||
| uses: astral-sh/setup-uv@v7 | ||
| with: | ||
| version: "0.6.5" | ||
| version: "0.12.0" | ||
| python-version: ${{ matrix.python-version }} | ||
| # enable-cache: true | ||
| # cache-dependency-glob: "pyproject.toml pdm.lock" | ||
|
|
||
| - name: Clear all caches | ||
| run: | | ||
| rm -rf ~/.cache/pip | ||
| rm -rf ~/.cache/uv | ||
| rm -rf ~/.cache/conda | ||
| rm -rf ~/.cache/npm | ||
| rm -rf ~/.cache/pip | ||
| rm -rf ~/.cache/uv | ||
| rm -rf ~/.cache/conda | ||
| rm -rf ~/.cache/npm | ||
|
|
||
| - name: Install package | ||
| run: uv sync --all-groups --reinstall | ||
|
|
@@ -47,12 +43,6 @@ jobs: | |
| - name: Run pytest | ||
| run: uv run pytest | ||
|
|
||
| - name: Check styling | ||
| run: uv run ruff format --check . | ||
|
|
||
| - name: Linting | ||
| run: uv run ruff check src/lanfactory | ||
|
|
||
| - name: Upload coverage reports to Codecov | ||
| uses: codecov/codecov-action@v7 | ||
| with: | ||
|
|
@@ -67,15 +57,11 @@ jobs: | |
| with: | ||
| persist-credentials: false | ||
|
|
||
| - name: Setup Python | ||
| uses: actions/setup-python@v6 | ||
| with: | ||
| python-version: "3.12" | ||
|
|
||
| - name: Install uv | ||
| uses: astral-sh/setup-uv@v7 | ||
| with: | ||
| version: "0.6.5" | ||
| version: "0.12.0" | ||
| python-version: ${{ matrix.python-version }} | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🎯 Functional Correctness | 🟠 Major | ⚡ Quick win Use a defined Python version for
Proposed fix- python-version: ${{ matrix.python-version }}
+ python-version: "3.12"🧰 Tools🪛 actionlint (1.7.12)[error] 64-64: property "python-version" is not defined in object type {} (expression) 🤖 Prompt for AI AgentsSource: Linters/SAST tools |
||
|
|
||
| - name: Install package (with notebook + backend deps) | ||
| run: uv sync --all-groups | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -157,3 +157,4 @@ explorations/ | |
| __marimo__/ | ||
|
|
||
| uv.lock | ||
| .vscode/ | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,21 +1,21 @@ | ||
| from .network_configs import ( | ||
| network_config_mlp, | ||
| network_config_choice_prob, | ||
| network_config_opn, | ||
| network_config_cpn, | ||
| train_config_mlp, | ||
| network_config_mlp, | ||
| network_config_opn, | ||
| train_config_choice_prob, | ||
| train_config_opn, | ||
| train_config_cpn, | ||
| train_config_mlp, | ||
| train_config_opn, | ||
| ) | ||
|
|
||
| __all__ = [ | ||
| "network_config_mlp", | ||
| "network_config_choice_prob", | ||
| "network_config_opn", | ||
| "network_config_cpn", | ||
| "train_config_mlp", | ||
| "network_config_mlp", | ||
| "network_config_opn", | ||
| "train_config_choice_prob", | ||
| "train_config_opn", | ||
| "train_config_cpn", | ||
| "train_config_mlp", | ||
| "train_config_opn", | ||
| ] |
Uh oh!
There was an error while loading. Please reload this page.