Skip to content

Fix false nf-test failure on empty stderr#4391

Open
sapunyangkut wants to merge 1 commit into
nf-core:devfrom
sapunyangkut:codex/issue-4327-nftest-stderr
Open

Fix false nf-test failure on empty stderr#4391
sapunyangkut wants to merge 1 commit into
nf-core:devfrom
sapunyangkut:codex/issue-4327-nftest-stderr

Conversation

@sapunyangkut

Copy link
Copy Markdown

What changed

  • only append the interactive nf-test failed error when stderr is non-empty
  • preserve the existing snapshot-difference and --no-prompts behavior
  • add a focused regression test for empty stderr, ordinary stderr, and snapshot-difference stderr

The previous bare else was attached to the snapshot-difference check, so a successful interactive nf-test run with empty stderr still appended an error. Snapshot stability runs the command twice, producing the two false failures reported in the issue.

Fixes #4327.

Validation

  • python -m pytest tests/components/test_components_snapshot_test.py -k display_nftest_output_stderr -q (3 passed)
  • Ruff 0.15.12 check and format check on both changed files
  • python -m py_compile on both changed Python files
  • git diff --check

PR checklist

  • The change is based on and targets dev
  • The change includes a focused regression test
  • The commit includes a DCO sign-off

Automation disclosure

This small bug fix was prepared and tested with OpenAI Codex automation and independently red-teamed by a separate local agent. The contributor remains responsible for the submitted change; no human review is claimed.

Signed-off-by: sapunyangkut <302607731+sapunyangkut@users.noreply.github.com>
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