Skip to content
Open
Show file tree
Hide file tree
Changes from 5 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -83,10 +83,10 @@ jobs:
~/.nox
.nox
key:
${{ runner.os }}-nox-${{ matrix.session.session }}-${{ env.pythonLocation }}-${{
${{ runner.os }}-nox-v2-${{ matrix.session.session }}-${{ env.pythonLocation }}-${{
hashFiles('**/uv.lock') }}-${{ hashFiles('**/noxfile.py') }}
restore-keys: |
${{ runner.os }}-nox-${{ matrix.session.session }}-${{ env.pythonLocation }}
${{ runner.os }}-nox-v2-${{ matrix.session.session }}-${{ env.pythonLocation }}

- name: Setup mise
uses: jdx/mise-action@146a28175021df8ca24f8ee1828cc2a60f980bd5 # v3
Expand Down
11 changes: 6 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -56,10 +56,10 @@ repos:
rev: v0.9.0
hooks:
- id: unasyncd
additional_dependencies: [ "ruff" ]
additional_dependencies: [ "ruff>=0.14.10,<0.15" ]
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Fix YAML bracket spacing to clear lint errors.

Line 59 and Line 76 use spaced bracket style that triggers YAMLlint brackets errors.

Proposed fix
-        additional_dependencies: [ "ruff>=0.14.10,<0.15" ]
+        additional_dependencies: ["ruff>=0.14.10,<0.15"]
...
-        types: [ python ]
+        types: [python]

Also applies to: 76-76

🧰 Tools
🪛 YAMLlint (1.38.0)

[error] 59-59: too many spaces inside brackets

(brackets)


[error] 59-59: too many spaces inside brackets

(brackets)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.pre-commit-config.yaml at line 59, The YAML uses spaced bracket array
syntax which triggers yamllint `brackets` errors: update the entries for
additional_dependencies to use compact brackets without spaces (e.g., change
additional_dependencies: [ "ruff>=0.14.10,<0.15" ] to additional_dependencies:
["ruff>=0.14.10,<0.15"]) and make the same change for the other occurrence;
ensure you only remove the space after `[` and before `]` while keeping the
string contents unchanged.

Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Version constraint should be in sync with pyproject.toml

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Oh I didnt saw that, I will fix it

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed 4dcc55f


- repo: https://github.com/charliermarsh/ruff-pre-commit
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We should also replace this hook with a system one, invoking mise targets

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think is a nice improvement, I will add it

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added 4dcc55f

rev: v0.13.0
rev: v0.14.10
hooks:
- id: ruff-check
types_or: [ python, pyi ]
Expand All @@ -71,16 +71,17 @@ repos:
hooks:
- id: lint
name: lint
entry: mise run lint:pre-commit
language: python
entry: tools/mise run lint:pre-commit
Copy link
Copy Markdown
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should not be needed, as mise is already installed by the gh action

Copy link
Copy Markdown
Contributor Author

@Ckk3 Ckk3 Mar 31, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since this repo already have a mise in this folder I thought will be nice to already use it in CI and in local env.
What do you think about it?

language: system
types: [ python ]
pass_filenames: false
require_serial: true
Comment on lines +79 to 83
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

Fix bracket spacing.

Same bracket spacing issue at line 81.

Proposed fix
-        types: [ python ]
+        types: [python]
📝 Committable suggestion

‼️ IMPORTANT
Carefully review the code before committing. Ensure that it accurately replaces the highlighted code, contains no missing lines, and has no issues with indentation. Thoroughly test & benchmark the code to ensure it meets the requirements.

Suggested change
entry: tools/mise run lint:pre-commit
language: system
types: [ python ]
pass_filenames: false
require_serial: true
entry: tools/mise run lint:pre-commit
language: system
types: [python]
pass_filenames: false
require_serial: true
🧰 Tools
🪛 YAMLlint (1.38.0)

[error] 81-81: too many spaces inside brackets

(brackets)


[error] 81-81: too many spaces inside brackets

(brackets)

🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.

In @.pre-commit-config.yaml around lines 79 - 83, Fix the bracket spacing for
the pre-commit hook's types list: locate the block with the "types:" key (the
entry using tools/mise run lint:pre-commit) and remove the extra space inside
the square brackets so it reads types: [python] (or use a quoted single-item
list like types: ["python"]) to match the project's YAML style.


- repo: local
hooks:
- id: task-docs
name: Tasks documentation
entry: mise run render:usage
entry: tools/mise run render:usage
language: system
files: ^mise.toml$
pass_filenames: false
Expand Down
2 changes: 1 addition & 1 deletion mise.toml
Original file line number Diff line number Diff line change
Expand Up @@ -256,4 +256,4 @@ run = [

[tasks."render:usage"]
description = "Generate tasks documentation"
run = ["mise generate task-docs > tasks.md"]
run = ["tools/mise generate task-docs > tasks.md"]
5 changes: 3 additions & 2 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ dev = [
]
codeflash = ["codeflash"]
doc = ["git-cliff>=2.6.1"]
lint = ["basedpyright", "ruff", "vulture", "slotscheck>=0.16.5"]
lint = ["basedpyright", "ruff>=0.14.10,<0.15", "vulture", "slotscheck>=0.16.5"]
mysql = ["asyncmy", "cryptography"]
postgres = ["asyncpg>=0.29.0", "psycopg[binary,pool]>=3.2.3"]
test = [
Expand Down Expand Up @@ -323,6 +323,7 @@ exclude = [
".ruff_cache",
".svn",
".venv",
"__pycache__",
"__pypackages__",
"_build",
"buck-out",
Expand All @@ -333,7 +334,7 @@ exclude = [
"tests/codegen/snapshots",
"alembic/* ",
]
src = ["src/strawchemy", "tests"]
src = ["src", "tests"]

[tool.ruff.lint]
select = ["ALL"]
Expand Down
4 changes: 2 additions & 2 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading