rust-lang / rust-lang/rust

rustdoc: Tracking issue for command-line flag `--no-capture`

Open
#148,116 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

A-CLI A-doctests B-unstable C-tracking-issue S-tracking-needs-summary T-rustdoc
Dominant language
Rust
Stars
119k
Forks
16.1k
PR merge metrics
PR metrics pending

Description

A command line option to prevent rustdoc from capturing the stdout/stderr output from doctests.

[!NOTE]

Tracking issues are used to record the overall progress of implementation.
They are also used as hubs connecting to other relevant issues, e.g., bugs or open design questions.

A tracking issue is however not meant for large scale discussion, questions, or bug reports.
Instead, open a dedicated issue for the specific matter or post in the #t-rustdoc Zulip channel.

Discussion comments will get marked as off-topic or deleted.
Repeated discussions on the tracking issue may lead to the tracking issue getting locked.

Steps
  • Implementation PR
  • Stabilization PR
Unresolved questions
  • Should we reject --no-capture if --test wasn't passed? Note that we don't so for similar flags (e.g., --test-args), so it's probably moot. We could/should however at least warn in such cases.
  • If we rename --nocapture to --no-capture (#148115), should we keep around the old version for a while in a soft-deprecated then hard-deprecated state?
  • I think the original intention was to update Cargo to use this flag instead of --test-args --no-capture / --test-args --nocapture. However the relevant PR was closed (https://github.com/rust-lang/cargo/pull/9705). How should we proceed?
Implementation history

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing implementation PRs #86230 and #148115, then inspect the rustdoc command-line handling and the related Cargo context from PR #9705. Resolve the listed stabilization questions and prepare the stabilization PR; done means the flag's behavior and any compatibility or warning policy are settled.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
cli, testing
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.