Project maintenance alignment #123

Closed
opened 2026-07-22 07:04:31 +00:00 by coding-agent-marvin8 · 1 comment
coding-agent-marvin8 commented 2026-07-22 07:04:31 +00:00 (Migrated from codeberg.org)

Bring CANG in line with the standard project maintenance checklist from current-tasks.md (2026-07-19 session). Covers CI, scaffolding, container, code fixes, and versioning — 19 items total tracked in TODO.md.

Bring CANG in line with the standard project maintenance checklist from current-tasks.md (2026-07-19 session). Covers CI, scaffolding, container, code fixes, and versioning — 19 items total tracked in TODO.md.
coding-agent-marvin8 commented 2026-07-22 07:04:52 +00:00 (Migrated from codeberg.org)

Plan of attack

19 maintenance tasks across five areas, all tracked in TODO.md with collapsible prose context.

Area 1: CI fixes (3 tasks)

  1. Replace curl | sh with astral-sh/setup-uv@v5 — checks, publish, deploy-docs jobs in ci.yml; also weekly-checks.yml. Remove the echo "$HOME/.local/bin" >> $GITHUB_PATH lines (action handles PATH).

  2. Gitleaks checksum verification — read version from .pre-commit-config.yaml, download both tarball and checksums file, verify with sha256sum -c before extracting.

  3. Add publish-container CI job — triggered on release, needs: [gitleaks, checks], buildah bud --isolation chroot --platform linux/amd64, push to registry.marvin8.zone/marvin8/cang:latest and :VERSION.

Area 2: Scaffolding (9 tasks)

  1. Add .gitleaks.toml — standard form: title + extend useDefault.
  2. Add standalone ruff.toml — line-length 120, TID252, mccabe, expanded rules. Remove inline [tool.ruff] from pyproject.toml.
  3. Add LICENSE.md — AGPL-3.0-or-later full text.
  4. Add README badges — docs, pepy, gitleaks, pysentry, ty, complexipy.
  5. Add .editorconfig — no insert_final_newline = false override.
  6. Bump uv_build floor>=0.11.0,<0.12.0 in [build-system] requires.
  7. Rename ruff pre-commit hookruffruff-check in .pre-commit-config.yaml.
  8. Add [tool.deptry.per_rule_ignores] — DEP002 for starlette, python-multipart, pydantic-settings.
  9. Fully document source files — add docstrings to all public modules/classes/functions under src/ so no blanket # ruff: noqa: directives are needed. Test files may keep per-file D100/D103 noqa.

Area 3: Container (4 tasks)

  1. Make Containerfile self-containeduv build --wheel in builder stage, pin UV_VERSION from pyproject.toml via ARG UV_VERSION + COPY --from=ghcr.io/astral-sh/uv:${UV_VERSION}, pre-compile bytecode with UV_COMPILE_BYTECODE=1 + python -m compileall.
  2. Add --annotation flags to justfile — matching every OCI label in Containerfile.
  3. Publish with latest + $VERSION only — remove docker.io push, use only registry.marvin8.zone. Justfile and CI.
  4. Extract reset-release-notes recipe — standalone justfile recipe; fediverse-post calls it.

Area 4: Code fixes (3 tasks)

  1. URL-encode camera names and time strings — in web/routes/clips.py and _build_query_string in web/routes/snapshots.py.
  2. Remove dead list_days and list_days_with_stats — from db.py.
  3. Fix snapshots time bar labels — dynamic labels matching displayed range, fix rightmost 21 → 24.

Area 5: Versioning (1 task)

  1. Switch to calverYYYY.MM.DD format. Touches pyproject.toml, [tool.bumpversion], Release-Notes.md template, CHANGELOG.md, and the justfile release recipe.

Rough commit sequence

  1. :wrench: add scaffolding files (gitleaks.toml, ruff.toml, LICENSE.md, .editorconfig)
  2. :art: add README badges, bump uv_build, rename ruff hook, add deptry ignores
  3. :green_heart: replace curl|sh with setup-uv, gitleaks checksums, add publish-container job
  4. :whale: make Containerfile self-contained, add annotations, simplify tags
  5. :page_facing_up: document source files, extract reset-release-notes recipe
  6. :bug: fix URL encoding and dead functions in db.py
  7. >🐛 fix snapshots time bar labels (dynamic range + 21→24)`
  8. :bookmark: switch to calver versioning
## Plan of attack 19 maintenance tasks across five areas, all tracked in TODO.md with collapsible prose context. ### Area 1: CI fixes (3 tasks) 1. **Replace `curl | sh` with `astral-sh/setup-uv@v5`** — checks, publish, deploy-docs jobs in `ci.yml`; also `weekly-checks.yml`. Remove the `echo "$HOME/.local/bin" >> $GITHUB_PATH` lines (action handles PATH). 2. **Gitleaks checksum verification** — read version from `.pre-commit-config.yaml`, download both tarball and checksums file, verify with `sha256sum -c` before extracting. 3. **Add `publish-container` CI job** — triggered on release, `needs: [gitleaks, checks]`, `buildah bud --isolation chroot --platform linux/amd64`, push to `registry.marvin8.zone/marvin8/cang:latest` and `:VERSION`. ### Area 2: Scaffolding (9 tasks) 4. **Add `.gitleaks.toml`** — standard form: title + extend useDefault. 5. **Add standalone `ruff.toml`** — line-length 120, TID252, mccabe, expanded rules. Remove inline `[tool.ruff]` from `pyproject.toml`. 6. **Add `LICENSE.md`** — AGPL-3.0-or-later full text. 7. **Add README badges** — docs, pepy, gitleaks, pysentry, ty, complexipy. 8. **Add `.editorconfig`** — no `insert_final_newline = false` override. 9. **Bump `uv_build` floor** — `>=0.11.0,<0.12.0` in `[build-system] requires`. 10. **Rename ruff pre-commit hook** — `ruff` → `ruff-check` in `.pre-commit-config.yaml`. 11. **Add `[tool.deptry.per_rule_ignores]`** — DEP002 for starlette, python-multipart, pydantic-settings. 12. **Fully document source files** — add docstrings to all public modules/classes/functions under `src/` so no blanket `# ruff: noqa:` directives are needed. Test files may keep per-file D100/D103 noqa. ### Area 3: Container (4 tasks) 13. **Make Containerfile self-contained** — `uv build --wheel` in builder stage, pin UV_VERSION from pyproject.toml via `ARG UV_VERSION` + `COPY --from=ghcr.io/astral-sh/uv:${UV_VERSION}`, pre-compile bytecode with `UV_COMPILE_BYTECODE=1` + `python -m compileall`. 14. **Add `--annotation` flags to justfile** — matching every OCI label in Containerfile. 15. **Publish with `latest` + `$VERSION` only** — remove docker.io push, use only `registry.marvin8.zone`. Justfile and CI. 16. **Extract `reset-release-notes` recipe** — standalone justfile recipe; `fediverse-post` calls it. ### Area 4: Code fixes (3 tasks) 17. **URL-encode camera names and time strings** — in `web/routes/clips.py` and `_build_query_string` in `web/routes/snapshots.py`. 18. **Remove dead `list_days` and `list_days_with_stats`** — from `db.py`. 19. **Fix snapshots time bar labels** — dynamic labels matching displayed range, fix rightmost 21 → 24. ### Area 5: Versioning (1 task) 20. **Switch to calver** — `YYYY.MM.DD` format. Touches `pyproject.toml`, `[tool.bumpversion]`, `Release-Notes.md` template, `CHANGELOG.md`, and the justfile `release` recipe. ### Rough commit sequence 1. `:wrench: add scaffolding files (gitleaks.toml, ruff.toml, LICENSE.md, .editorconfig)` 2. `:art: add README badges, bump uv_build, rename ruff hook, add deptry ignores` 3. `:green_heart: replace curl|sh with setup-uv, gitleaks checksums, add publish-container job` 4. `:whale: make Containerfile self-contained, add annotations, simplify tags` 5. `:page_facing_up: document source files, extract reset-release-notes recipe` 6. `:bug: fix URL encoding and dead functions in db.py` 7. \>:bug: fix snapshots time bar labels (dynamic range + 21→24)` 8. `:bookmark: switch to calver versioning`
Sign in to join this conversation.
No labels
No milestone
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
marvin8/cang#123
No description provided.