Skip to content

chore: regenerate protocols for the number pool range kind - #1371

Draft
polmichel wants to merge 2 commits into
infrahub-developfrom
pmi-number-pool-range-protocols
Draft

polmichel wants to merge 2 commits into
infrahub-developfrom
pmi-number-pool-range-protocols

Conversation

@polmichel

@polmichel polmichel commented Sep 18, 2026

Copy link
Copy Markdown
Contributor

Why

Infrahub gains a CoreNumberPoolRange core kind, and CoreNumberPool gains a ranges
relationship while its start_range and end_range become optional.

Needed by opsmill/infrahub#10682.

What changed

infrahub_sdk/protocols.py only, regenerated.

Relates to

Infrahub companion PR: opsmill/infrahub#10682


🤖 Generated with Claude Code

https://claude.ai/code/session_01TgXERZQRu7W5V8zCyUEAVA


Summary by cubic

Regenerates infrahub_sdk/protocols.py to match the new CoreNumberPoolRange kind and updated CoreNumberPool model, and refreshes the generator's golden fixtures that gained the new range classes from the regenerated import line. This keeps generated protocols in sync with Infrahub so backend-validate-generated passes before the submodule pointer moves.

  • CoreNumberPool.start_range and end_range become IntegerOptional, and a ranges relationship is added.
  • Adds CoreNumberPoolRange and CoreNumberPoolRangeSync with start, end, allocation_weight, and pool.
  • The fixture updates are mechanical consequences of the protocols module change, not a schema change.

Written for commit 40e6d8c. Summary will update on new commits.

Review in cubic

CoreNumberPool gains a ranges relationship and its start_range and end_range
become optional; the new CoreNumberPoolRange kind is added.

Generated from the Infrahub core models, not written by hand.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01TgXERZQRu7W5V8zCyUEAVA
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Sep 18, 2026

Copy link
Copy Markdown

Deploying infrahub-sdk-python with  Cloudflare Pages  Cloudflare Pages

Latest commit: 40e6d8c
Status: ✅  Deploy successful!
Preview URL: https://edf03355.infrahub-sdk-python.pages.dev
Branch Preview URL: https://pmi-number-pool-range-protoc.infrahub-sdk-python.pages.dev

View logs

@cubic-dev-ai cubic-dev-ai Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

No issues found across 1 file

Re-trigger cubic

… kind

The generator builds its import line by introspecting infrahub_sdk.protocols,
so regenerating that module in 100d6b3 to add CoreNumberPoolRange changed the
output for every user schema. The golden fixtures still carried the previous
import line, failing test_render_user_schema_matches_golden.

Only line 9 changes in each fixture, gaining CoreNumberPoolRange and
CoreNumberPoolRangeSync.

Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
@codecov

codecov Bot commented Sep 18, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

@@                 Coverage Diff                  @@
##           infrahub-develop    #1371      +/-   ##
====================================================
- Coverage             86.28%   86.05%   -0.23%     
====================================================
  Files                   149      149              
  Lines                 14537    14338     -199     
  Branches               1995     1958      -37     
====================================================
- Hits                  12543    12339     -204     
  Misses                 1431     1431              
- Partials                563      568       +5     
Flag Coverage Δ
integration-tests 43.08% <100.00%> (-0.52%) ⬇️
python-3.10 60.96% <100.00%> (-0.61%) ⬇️
python-3.11 60.96% <100.00%> (-0.61%) ⬇️
python-3.12 60.96% <100.00%> (-0.59%) ⬇️
python-3.13 60.97% <100.00%> (-0.59%) ⬇️
python-3.14 60.97% <100.00%> (-0.58%) ⬇️
python-filler-3.12 22.07% <0.00%> (+0.32%) ⬆️

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

Files with missing lines Coverage Δ
infrahub_sdk/protocols.py 100.00% <100.00%> (ø)

... and 4 files with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

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