Skip to content

fix(ci): keep failed test IDs in the service image shard summary #5103

Closed

Description

@dan-petty

Problem Description

The shard test step of .github/workflows/service-image-test.yml gives pytest the option -rs. The -r option of pytest replaces the default report characters fE. Thus the short test summary of a shard shows only the skip reasons. It does not show the FAILED <node id> - <message> lines and the ERROR lines. A failed shard log does not name its failed test IDs, which AGENTS.md rule 14 tells us to keep. Pull request #5079 (issue #4642) added the option. The issue asked only to add the skip reasons. The devops ci shard row already uses -rfEs for the same reason (#5006).

Reproduction Steps

  1. Write a test file with one passing, one failing and one skipped test.
  2. Run python -m pytest -q -rs -n 2 <file>.
  3. Run python -m pytest -q -rfEs -n 2 <file>.

Expected vs Actual Behavior

Expected: the summary has a FAILED <file>::test_bad - assert 1 == 2 line and a SKIPPED line.

Actual: with -rs, the summary has only SKIPPED [1] <file>:4: why skipped. With -rfEs, it has both lines.

Environment Diagnostics

pytest 9.1.1 with pytest-xdist, as in the project lock file. tests/commands/test_ci.py locks the wrong value with '"-rs"' in test_run.

Logs, Traces, or Terminal Output

== -rs
SKIPPED [1] test_rs_probe.py:4: why skipped
== -rfEs
FAILED test_rs_probe.py::test_bad - assert 1 == 2
SKIPPED [1] test_rs_probe.py:4: why skipped

Fix: change "-rs" to "-rfEs" in the shard test step, and assert '"-rfEs"' in test_run in test_service_image_test_ci_job_invariants.

Pre-Submission Checklist

  • I have verified that no sensitive credentials, private keys, or internal tokens are contained in this issue report.
  • I have checked existing issues and pull requests to ensure this is not a duplicate.

Source: #5079

Activity

  1. added
    source/agent
    type/bug
    scope/ci
    status/new
    value/medium
    effort/low
    on Nov 12, 2026
  2. dan-petty commented on Nov 12, 2026

    @dan-petty
    OwnerAuthor
  3. added
    priority/p2-medium
    owner/agent
    status/in-progress
    status/in-review
    and removed
    status/new
    status/in-progress
    on Nov 12, 2026
  4. removed
    status/in-review
    owner/agent
    on Nov 12, 2026
  5. devops-cli-service commented on Nov 12, 2026

    @devops-cli-service
    Contributor
  6. devops-cli-service commented on Nov 12, 2026

    @devops-cli-service
    Contributor

    Live since 2026-11-12 15:46 UTC

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

    effort/lowpriority/p2-mediumscope/cisource/agenttype/bugvalue/medium

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions