Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 3 additions & 3 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v5.0.0 # Use the ref you want to point at
rev: v6.0.0 # Use the ref you want to point at
hooks:
- id: trailing-whitespace
- id: check-ast
Expand All @@ -17,7 +17,7 @@ repos:
- id: check-toml

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: 'v0.11.4'
rev: 'v0.15.5'
hooks:
- id: ruff
args: [--fix, --exit-non-zero-on-fix]
Expand All @@ -26,7 +26,7 @@ repos:
types_or: [python, jupyter]

- repo: https://github.com/pre-commit/mirrors-mypy
rev: v1.15.0
rev: v1.19.1
hooks:
- id: mypy
entry: python3 -m mypy --config-file pyproject.toml
Expand Down
2 changes: 1 addition & 1 deletion cycquery/ops.py
Original file line number Diff line number Diff line change
Expand Up @@ -2891,7 +2891,7 @@ class RandomizeOrder(QueryOp):
--------
>>> RandomizeOrder()(table)

Warnings:
Warnings
--------
Becomes quite slow on large tables.

Expand Down
2 changes: 1 addition & 1 deletion cycquery/util.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@

def get_attr_name(name: str) -> str:
"""Get attribute name (second part of first.second)."""
return name.split(".")[-1]
return name.rsplit(".", maxsplit=1)[-1]


@dataclass
Expand Down
2 changes: 1 addition & 1 deletion tests/conftest.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ def _setup_sqlite_schema_attachments(db_path: str, schema_files: dict[str, str])
Dictionary mapping schema names to their database file paths.

"""
from cycquery.orm import Database
from cycquery.orm import Database # noqa: PLC0415 - Lazy import for monkeypatching

# Store the attachment information globally
_SCHEMA_ATTACHMENTS[db_path] = schema_files
Expand Down
Loading