Skip to content

Slim CI to lint+build for the deprecation shim - #35

Merged
Xof merged 1 commit into
mainfrom
slim-ci-for-shim
Jun 21, 2026
Merged

Slim CI to lint+build for the deprecation shim#35
Xof merged 1 commit into
mainfrom
slim-ci-for-shim

Conversation

@Xof

@Xof Xof commented Jun 21, 2026

Copy link
Copy Markdown
Owner

Gets CI green again. After 2.1.0 turned the package into a re-export shim, CI was red on every branch for two reasons:

  1. lintruff check tripped E402: the from django_pg_utils.locks import … re-export sat after the warnings.warn(...) call.
  2. test matrix — the 2.1.0 commit deleted tests/, but ci.yml still ran a full PostgreSQL × Django × psycopg pytest matrix, and pyproject.toml still pointed DJANGO_SETTINGS_MODULE at the deleted tests.django_settings. Every job failed.

Changes

  • src/django_pglocks/__init__.py — move the re-export to module top (fixes E402). The DeprecationWarning still fires on first import.
  • .github/workflows/ci.yml — drop test-pr/test-full; keep lint (ruff + mypy) + build. A frozen shim that only re-exports has nothing to exercise.
  • pyproject.toml — remove the dangling [tool.pytest.ini_options] and the unused pytest dev dependencies.

Verified locally

ruff check ✅ · ruff format --check ✅ · mypy ✅ · uv build ✅ · import django_pglocks still warns and resolves advisory_lock to django_pg_utils.locks._sync (i.e. from django-pgware).

Note: no effect on the published 2.1.0 artifact — this is repo hygiene only.

The 2.1.0 shim deleted its test suite, but CI still ran a PostgreSQL/Django
pytest matrix (every job failed) and the lint job tripped E402 on the
re-export sitting after the deprecation warning.

- Move the re-export to module top (fixes ruff E402); the warning still fires.
- Drop the test-pr/test-full matrix from ci.yml — nothing to exercise here.
- Remove the dangling pytest config (pointed at the deleted tests.django_settings)
  and the now-unused pytest dev dependencies.

CI is now lint (ruff + mypy) + build, right-sized for a frozen shim.
@Xof
Xof merged commit 48cdd52 into main Jun 21, 2026
2 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant