Skip to content

test_falsification_shining_codex.py asserts a config filename views-models retired #489

Closed

Description

@Polichinel

What

TestF1ConfigFiles in tests/test_falsification_shining_codex.py asserts that
views-models/models/shining_codex/configs/config_deployment.py exists. It does not. Two tests
fail locally:

FAILED TestF1ConfigFiles::test_config_deployment_exists
FAILED TestF1ConfigFiles::test_all_required_configs_exist

Why

views-models commit 3f2d98ec — "feat(#490): config_maturity.py for the 31 cm r2darts2 models —
only the 38 stepshifter sources remain on the legacy vocabulary (#496)"
— replaced
config_deployment.py with config_maturity.py. Deliberate vocabulary migration on their side.
Our test still encodes the old name.

Why nobody noticed

The class is @pytest.mark.skipif(not _SHINING_CODEX.exists()), and _SHINING_CODEX is a
relative sibling path (parents[1].parent / "views-models/models/shining_codex"). In CI the
sibling repo is absent, so all four tests skip and the job is green. The assertion only runs on a
machine that has both repos checked out side by side.

So this is a test that can only fail on a developer's laptop, and only for reasons that live in
another repository. That is the more interesting finding than the stale filename.

Suggested fix

Two separate decisions:

  1. The filename. Either accept config_maturity.py as the replacement, or accept either name.
    Worth checking with views-models which is intended for shining_codex specifically — chore: sync main back into development after v1.14.0 #496 says
    only the 31 r2darts2 models moved and 38 stepshifter sources stayed on the legacy vocabulary, so
    whether shining_codex is in the moved set needs confirming rather than assuming.
  2. Whether this test should exist here at all. A cross-repo filesystem assertion against a
    relative sibling path is green in CI, red on a laptop, and silent about which. If the contract
    matters it belongs in views-models' own suite; if it does not, this belongs in a post-mortem
    note rather than a test.

Found while running the full suite for #487 (ACLED cursor migration). Unrelated to that change —
confirmed by the other repo's git history — so it was not fixed there.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions