Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

docs(ref): Deprecate 'package.authors' #15068

Merged
merged 2 commits into from
Jan 16, 2025
Merged

Conversation

epage
Copy link
Contributor

@epage epage commented Jan 15, 2025

What does this PR try to resolve?

This was left as a future-possibility in
RFC #3052.
Without a clear role for this field within Cargo/crates.io,
there seems little reason to actively support it (e.g. #14949, #15027),
including working through feature requests.
I see the potential for having some fields with more specific roles
(where to go for support, where to go for disclosing vulnerabilities, etc)
but even these run into the mutable data problem of authors.
Users can always manage metadata for their own purposes through package.metadata.

The RFC called out clap as an example of something that uses this.
Clap no longer does by default but users can opt-in through a
help_template.

For now, this notes the status in the documentation.
When we have[user control over Cargo lint (#12235)
(and figure out namespacing with lints that overlap with Rust),
we can give a warning on this.
Based on feedback from users, we can evaluate removing this field in a
future edition.

This is as discussed in a recent Cargo team meeting

How should we test and review this PR?

Additional information

We may want to consider doing similar for badges

epage added 2 commits January 15, 2025 11:08
This was left as a future-possibility in
[RFC rust-lang#3052](https://rust-lang.github.io/rfcs/3052-optional-authors-field.html).
Without a clear role for this field within Cargo/crates.io,
there seems little reason to actively support it (e.g. rust-lang#14949, rust-lang#15027),
including working through feature requests.
I see the potential for having some fields with more specific roles
(where to go for support, where to go for disclosing vulnerabilities, etc)
but even these run into the mutable data problem of `authors`.
Users can always manage metadata for their own purposes through `package.metadata`.

The RFC called out clap as an example of something that uses this.
Clap no longer does by default but users can opt-in through a
`help_template`.

For now, this notes the status in the documentation.
When we have[user control over Cargo lint (rust-lang#12235)
(and figure out namespacing with lints that overlap with Rust),
we can give a warning on this.
Based on feedback from users, we can evaluate removing this field in a
future edition.

We may want to consider doing similar for `badges`
@rustbot
Copy link
Collaborator

rustbot commented Jan 15, 2025

r? @ehuss

rustbot has assigned @ehuss.
They will have a look at your PR within the next two weeks and either review your PR or reassign to another reviewer.

Use r? to explicitly pick a reviewer

@rustbot rustbot added A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties. labels Jan 15, 2025
@epage
Copy link
Contributor Author

epage commented Jan 15, 2025

CI failure seems unrelated

     Running benches/global_cache_tracker.rs (target/debug/deps/global_cache_tracker-c5606e28ceb8cc09)
Gnuplot not found, using plotters backend
     Running benches/resolve.rs (target/debug/deps/resolve-954fd14fc20489a6)
Gnuplot not found, using plotters backend
hint: Using 'master' as the name for the initial branch. This default branch name
hint: is subject to change. To configure the initial branch name to use in all
hint: of your new repositories, which will suppress this warning, call:
hint:
hint: 	git config --global init.defaultBranch <name>
hint:
hint: Names commonly chosen instead of 'master' are 'main', 'trunk' and
hint: 'development'. The just-created branch can be renamed via this command:
hint:
hint: 	git branch -m <name>
Initialized empty Git repository in /home/runner/work/cargo/cargo/target/tmp/bench/index/
From https://github.com/rust-lang/crates.io-index-archive
 * branch                85f7bfd61ea4fee08ec68c468762e886b2aebec6 -> FETCH_HEAD
Testing resolve_ws/cargo
    Updating `local-snapshot` index

thread 'main' panicked at benches/benchsuite/benches/resolve.rs:47:6:
called `Result::unwrap()` on an `Err` value: no matching package named `clap` found
location searched: `local-snapshot` index (which is replacing registry `crates-io`)
required by package `cargo v0.58.0 (/home/runner/work/cargo/cargo/target/tmp/bench/workspaces/cargo)`
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace

@weihanglo
Copy link
Member

See #15065 (comment). Haven't figured out the root cause.

@weihanglo weihanglo added this pull request to the merge queue Jan 16, 2025
Merged via the queue into rust-lang:master with commit 2909c01 Jan 16, 2025
21 checks passed
@epage epage deleted the deprecate branch January 16, 2025 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-documenting-cargo-itself Area: Cargo's documentation S-waiting-on-review Status: Awaiting review from the assignee but also interested parties.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants