Manual merge develop into infrahub-develop

Merged
PO
4d ago
+4016-7025

Supersedes #1525, which fails the python-lint check after merging.

Summary

Merges develop into infrahub-develop.

Conflicts resolved

Git merged the branches without text conflicts. The merged code still failed the type check and one unit test, because the two branches changed tests/unit/test_schema_offline_validation.py in incompatible ways:

  • develop (#1523) renamed the OutOfEnumCase field invalid_value to expected_input and expected_reason, and made the tests compare exact error messages.
  • infrahub-develop (e5d1ed68) added a dropdown-choice-state case that still used invalid_value. It also changed the _schema_with_choices fixture so that it builds a Dropdown attribute instead of a Text attribute.

The fix in d10cef24:

  • Ports the dropdown-choice-state case to expected_input="removed" and expected_reason="Input should be 'present' or 'absent'". The error reason is the one the validator returns.
  • Changes the exact message that test_choice_bad_color_is_rejected expects from ...attributes[0].Text.choices[0].color... to ...attributes[0].Dropdown.choices[0].color..., to match the new fixture.

Validation

  • uv run invoke format lint-code passes.
  • uv run invoke docs-validate passes.
  • Unit tests: 3143 passed. Locally, the subprocess tests in tests/unit/pytest_plugin/test_plugin.py were not run, because the testcontainers plugin crashes on this machine (invalid CPU frequency data). CI runs them.
  • Integration tests were not run.

šŸ¤– Generated with Claude Code