Skip to content

feat(codegen): add dry-run registry + codegen management command#117

Merged
davecoates merged 1 commit intomainfrom
feature/issue114-codegen-command
Feb 26, 2026
Merged

feat(codegen): add dry-run registry + codegen management command#117
davecoates merged 1 commit intomainfrom
feature/issue114-codegen-command

Conversation

@davecoates
Copy link
Copy Markdown
Contributor

Includes dry-run support, new REGISTRY setting/command.

Resolves #114

@davecoates davecoates force-pushed the feature/issue114-codegen-command branch from e59d384 to 498bc3a Compare February 5, 2026 03:15
@codecov
Copy link
Copy Markdown

codecov Bot commented Feb 5, 2026

Codecov Report

❌ Patch coverage is 81.94444% with 13 lines in your changes missing coverage. Please review.
✅ Project coverage is 81.22%. Comparing base (7e93ac1) to head (a033053).
⚠️ Report is 8 commits behind head on main.

Files with missing lines Patch % Lines
...ce_platform/codegen/management/commands/codegen.py 83.01% 9 Missing ⚠️
...s/ap-codegen/alliance_platform/codegen/registry.py 71.42% 4 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main     #117      +/-   ##
==========================================
+ Coverage   79.24%   81.22%   +1.97%     
==========================================
  Files          93       94       +1     
  Lines        6554     6646      +92     
==========================================
+ Hits         5194     5398     +204     
+ Misses       1360     1248     -112     
Flag Coverage Δ
ap-audit 78.46% <ø> (ø)
ap-codegen 79.69% <81.94%> (+13.45%) ⬆️
ap-core 68.38% <ø> (ø)
ap-frontend 78.75% <ø> (+0.69%) ⬆️
ap-ordered-model 94.46% <ø> (ø)
ap-pdf 81.69% <ø> (ø)
ap-server-choices 89.11% <ø> (ø)
ap-storage 89.52% <ø> (ø)
ap-ui 75.32% <ø> (ø)
django42 80.81% <81.94%> (+1.97%) ⬆️
django52 81.22% <81.94%> (+1.97%) ⬆️
py3.11 81.22% <81.94%> (+1.97%) ⬆️
py3.12 81.22% <81.94%> (+1.97%) ⬆️
py3.13 81.22% <81.94%> (+1.97%) ⬆️
py3.14 80.90% <81.94%> (+1.90%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

Copy link
Copy Markdown
Collaborator

@micahklaz micahklaz left a comment

Choose a reason for hiding this comment

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

Approved as the comment might not be a deal-breaker

if dry_run:
stats.files_pending.append(intermediate_file.target_path)
else:
stats.files_written.append(intermediate_file.target_path)
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

I think appending to files written after actually writing made more sense - that way if the writing process goes wrong (e.g. permission error) then the file path won't mistakenly be added to the list of files written.

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.

Makes sense, have moved it after

Includes dry-run support, new REGISTRY setting/command.

Resolves #114
@davecoates davecoates force-pushed the feature/issue114-codegen-command branch from 498bc3a to a033053 Compare February 26, 2026 22:30
@davecoates davecoates merged commit f6616e5 into main Feb 26, 2026
73 checks passed
@davecoates davecoates deleted the feature/issue114-codegen-command branch February 26, 2026 22:50
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.

Add codegen dry run option

2 participants