Skip to content

ci: test/cmocka/build/test-graph.json causes a merge conflict between almost every pair of PRs that register a test #3973

Open

Description

@zackees

Every port PR that registers its C test appends records to the single sorted file test/cmocka/build/test-graph.json (and module lines to rust/obs-build/tests/native.rs). Two PRs that each add a record next to each other conflict textually, even though their changes are independent.

Evidence (2026-11-07/08): the #1390 graph landing PRs #3914, #3937 and #3957 each had to merge master 3-5 times. Every PR ahead in the merge queue that touched the graph (#3944, #3928, #3946, #3907, #3965, ...) made the queue eject them as UNMERGEABLE, and port PRs merge more often than one CI cycle (~1 h), so a large graph PR rarely gets through without a hand-held window.

Options:

  1. Split the graph into one file per target (e.g. test/cmocka/build/test-graph.d/.json) assembled at configure time, the way tests.d fragments already work. Independent registrations never touch the same file.
  2. Keep one file but generate it, and add a .gitattributes merge=union or a custom JSON-array merge driver (only helps local merges, not GitHub's queue).
  3. For native.rs, discover registration modules automatically instead of listing them (the ci: discover oracle field adapters without per-port append blocks #3916 approach for oracle field adapters).

Option 1 plus 3 removes the conflict class. It needs a maintainer decision since it changes the graph layout #3832 introduced.

Refs #1390

Activity

  1. zackees commented on Nov 8, 2026

    @zackees
    MemberAuthor

    approved

  2. zackees commented on Nov 11, 2026

    @zackees
    MemberAuthor

    /ready

    The maintainer approved this layout change in the November 8 comment above; there is no remaining design-decision blocker. Current master still contains the single test/cmocka/build/test-graph.json and explicit native.rs entry point, and no open PR referencing this issue was found.

    Implementation scope: option 1 plus option 3, as approved. Acceptance criteria: split target registrations into deterministically assembled per-target fragments; preserve the exact resolved target/source/dependency/host-condition graph; discover native registration modules deterministically without a shared append list; demonstrate that two independent target additions touch disjoint registration files and combine cleanly; run existing graph/native registration tests plus focused RED→GREEN tests for assembly and discovery. Preserve all existing C tests and their assertions. Keep this separate from new port work.

    Classifying P2, size:M. This is triage only, not a claim or permission to bypass current back-pressure.

  3. added
    ready
    P2
    size:M
    on Nov 11, 2026
  4. zackees commented on Nov 11, 2026

    @zackees
    MemberAuthor

    Claiming: approved option 1 + 3 graph-layout migration. Coordinator coord-linux-20261110T1645; exclusive slot obs-studio10; local branch infra/3973-graph-fragments-slot10.

    1. Commit focused RED tests for deterministic per-target assembly and native registration discovery.
    2. Implement the migration and update actual consumers, preserving the effective graph across hosts and proving independent additions combine cleanly.
    3. Run focused graph/native/build checks and serial full lint; retain local RED/GREEN commits for coordinator review.

    Publication is held by coordinator instruction: no push, new PR or enqueue until explicitly released. Local implementation starts now; first PR timing depends on publication release.

  5. moved this from Triage to In progress in obs-rust Multiviewon Nov 11, 2026
  6. moved this from In progress to Ready in obs-rust Multiviewon Nov 12, 2026
  7. 22 remaining items

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

    P2readysize:M

    Type

    No type

    Projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions