Skip to content

fix: remove unnecessary selectors from harness conformance - #5370

Merged
marta-sd merged 3 commits into
martas/fep-1923-move-session-checkfrom
martas/fep-1924-remove-unneeded-selectors
Nov 13, 2026
Merged

marta-sd merged 3 commits into
martas/fep-1923-move-session-checkfrom
martas/fep-1924-remove-unneeded-selectors

Conversation

@marta-sd

@marta-sd marta-sd commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

What does this PR do?

Stops select_harnesses from selecting all harnesses for paths the probes don't use: nemo_gym/orchestration/ (the probes read only the sidecar config key name from it), nemo_gym/cli/, nemo_gym/eval/, nemo_gym/environment/, environments/, docker/, .agents/, and every .github/workflows/ file except harness-conformance.yml and cicd-main.yml. Nothing on the probe path imports nemo_gym/cli/, so the exceptions that kept cli/__init__.py and cli/utils.py selecting every harness are dropped. Also removes the responses_api_agents/shared/ entry, since that directory does not exist. Stacked on #5368.

Also:

  • A base given as a branch name that does not resolve locally falls back to origin/<name>, since a CI checkout has other branches only as remote refs. Without it, selection always fell back to running every harness.
  • changed_paths takes a compare mode, branch or commit, and select takes --compare. A push to main compares the commit before the push directly with HEAD, so a force-rewind selects what it removed. The docstring states that for a stacked PR the base is the parent branch.
  • New tests cover the rewind, a detached HEAD and a base that exists only as a remote-tracking ref.

Replaying the last 60 days of main (926 commits, 8 harnesses) through select_harnesses before and after this change:

Outcome Before After
All harnesses 517 (55.8%) 444 (47.9%)
Some harnesses 47 (5.1%) 48 (5.2%)
None 362 (39.1%) 434 (46.9%)

Validation

  • tests/unit_tests/test_harness_conformance_ci.py
  • pre-commit run on the changed files

Compatibility and benchmark impact

None. Only the set of PRs that trigger the non-blocking harness conformance check changes, and in CI it now follows the diff against the PR's base branch.

🤖 Generated with Claude Code

@marta-sd
marta-sd added this pull request to stack #5369 October 30, 2026 14:43
@copy-pr-bot

copy-pr-bot Bot commented Oct 30, 2026

Copy link
Copy Markdown

Auto-sync is disabled for draft pull requests in this repository. Workflows must be run manually.

Contributors can view more details about this message here.

@marta-sd

Copy link
Copy Markdown
Contributor Author

/ok to test 32262f4

@svcnvidia-nemo-ci svcnvidia-nemo-ci added area:ci CI workflows, test routing, and repository automation ci CI, automation, test queue, or workflow infrastructure work labels Oct 30, 2026
@marta-sd
marta-sd marked this pull request as ready for review November 2, 2026 14:22

@svcnvidia-nemo-ci svcnvidia-nemo-ci 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.

SHIP

LGTM — no concerns found. I reviewed both changed files and traced the affected probe setup, workflow callers, and empty-selection reporting. The exclusions preserve adapter-specific selection and conservative fallback for shared or unknown dependencies. The routing tests assert the new exclusions both alone and alongside adapter changes in either order.

This was static source review; I didn't execute tests.

Note: formal approval is not available for this request, so this review is posted as a comment only.

Review generated by codex. This was a full review. Request a full review with /review reset=true.

@marta-sd

marta-sd commented Nov 3, 2026

Copy link
Copy Markdown
Contributor Author

/ok to test 6edd02c

@giuliolovisotto giuliolovisotto 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.

Thanks for adding the remote-ref fallback. One remaining change-selection edge case, linked to the earlier discussion in the stack.

Comment thread scripts/check_suites/github_actions.py Resolved
@marta-sd
marta-sd force-pushed the martas/fep-1924-remove-unneeded-selectors branch from 6edd02c to 4f5881e Compare November 4, 2026 08:53
@marta-sd
marta-sd requested a review from a team as a code owner November 4, 2026 08:53
@marta-sd
marta-sd force-pushed the martas/fep-1924-remove-unneeded-selectors branch from 4f5881e to 3ca61f2 Compare November 4, 2026 09:36

@svcnvidia-nemo-ci svcnvidia-nemo-ci 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.

SHIP

LGTM — no concerns found in this follow-up.

The reported rewind issue is addressed: commit comparison diffs the supplied commit directly against HEAD, and the workflow selects that mode for main pushes. Branch comparisons retain merge-base behavior and the remote-ref fallback. The regression tests assert concrete selections for rewinds, remote-only refs, detached HEADs, deletions, and renames.

I completed the three-topic review of helper semantics, workflow integration, and tests/CLI preservation. The previously reviewed tree is unavailable, so I couldn't compare the complete inter-review delta; I didn't reopen the previously reviewed selector exclusions.

This was static source review; I didn't execute tests.

Review generated by codex. This was a findings-only review. Request a full review with /review reset=true.

@ko3n1g

ko3n1g commented Nov 10, 2026

Copy link
Copy Markdown
Contributor

/review-approve reset=true

@svcnvidia-nemo-ci svcnvidia-nemo-ci 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.

SHIP

LGTM — no concerns found.

I reviewed all four changed files and traced the selector's probe dependencies, the shared comparison helper, and the workflow/CLI integration. The selector retains adapter-specific selection and conservative fallback for shared or unknown dependencies.

The earlier rewind concern is addressed: commit mode compares the supplied commit directly with HEAD, and the workflow selects that mode for main pushes. Branch comparisons retain merge-base behavior and the remote-ref fallback. The regression tests assert concrete selections for rewinds, remote-only refs, detached HEADs, deletions, and renames.

Two completed child reports weren't available for consolidation, so I inspected their selector-dependency and workflow/CLI topics directly. This was static source review; I didn't execute tests.

Review generated by codex. This was a full review. Request a full review with /review reset=true.

@marta-sd

Copy link
Copy Markdown
Contributor Author

/ok to test 1a094a7

@giuliolovisotto giuliolovisotto 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.

Re-reviewed at 1a094a77fad5730e17b91bf6a996b4639cbaf694. The requested distinction between branch comparisons and direct push comparisons is implemented correctly, including force-rewind and remote-only base-ref regression coverage. All 68 focused selector/history tests passed.

Independent review found no blocking issue. A small follow-up remains: skipping nemo_gym/environment/ also skips affected OpenCode adapter tests until the scheduled full run. This does not block this change. Full CI and native harness rollouts were not run.

— @codex

marta-sd and others added 3 commits November 13, 2026 07:58
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Signed-off-by: Marta Stepniewska-Dziubinska <[email protected]>
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Signed-off-by: Marta Stepniewska-Dziubinska <[email protected]>
Co-Authored-By: Claude Sonnet 5.5 <[email protected]>
Signed-off-by: Marta Stepniewska-Dziubinska <[email protected]>
@marta-sd
marta-sd force-pushed the martas/fep-1924-remove-unneeded-selectors branch from 1a094a7 to a27ac8b Compare November 13, 2026 08:06
@marta-sd

Copy link
Copy Markdown
Contributor Author

/ok to test a27ac8b

@marta-sd
marta-sd enabled stacked auto-merge November 13, 2026 10:55
@marta-sd
marta-sd added this pull request to the merge queue Nov 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/43416799102

@github-merge-queue
github-merge-queue Bot removed this pull request from the merge queue because a pull request earlier in the stack was removed Nov 13, 2026
@marta-sd
marta-sd added this pull request to the merge queue Nov 13, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🔄 Merge queue validation started! You can track the progress here: https://github.com/NVIDIA-NeMo/Gym/actions/runs/43422356500

Merged via the queue into main with commit 49b0e8e Nov 13, 2026
76 checks passed
@marta-sd
marta-sd deleted the martas/fep-1924-remove-unneeded-selectors branch November 13, 2026 12:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area:ci CI workflows, test routing, and repository automation ci CI, automation, test queue, or workflow infrastructure work needs-review PR is ready for code review and waiting on a reviewer

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants