Repository navigation
feat(db): persist each import's row counts (#89) - #90
Merged
Merged
Conversation
… part) Migration 0003 adds total_rows, duplicate_rows_skipped and failed_rows to csv_files (row_count already holds the inserted count). Both loaders write them at registration and GET /api/csv/files returns them. Rows registered before 0003 keep NULL: their counts were never recorded. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019YPoXzBSj89ZHgw7nfTmbB
amar-python
changed the base branch from
fix/issue-81-84-alembic-registry-unique
to
main
October 26, 2026 06:36
amar-python
pushed a commit
that referenced
this pull request
Oct 26, 2026
Brings in #87, #90 and #86. No conflicts. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_019YPoXzBSj89ZHgw7nfTmbB
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #89. This is the last ART Milestone 1 item (BR-34, part).
Stacked on #87. It needs that PR's Alembic setup, so its base is
fix/issue-81-84-alembic-registry-unique. Merge #87 first. GitHub then retargets this PR tomain.What changes
0003_import_counts. Addstotal_rows,duplicate_rows_skippedandfailed_rowstocsv_files.row_countalready stores the inserted count. Downgrade drops the three columns.duplicate_rows_skippedis 0, which matches the response.GET /api/csv/filesreturns the counts. The response only gains fields, so existing clients are unaffected.api/db.py. Mirrors the new columns.test_migrations. Now expects head0003.Out of scope: reconciling edited and excluded rows. That needs the staged import and is planned for M6.
Evidence
Run on local PostgreSQL 16, using the replica of the CI integration job.
scripts/test_report.py --strictevals/runner.pyp,i,s,etests/test_import_counts.py+tests/test_migrations.pyscripts/lint.shGenerated by Claude Code