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

chore: hide internal features #2026

Merged
merged 3 commits into from
Mar 12, 2024
Merged

Conversation

nyurik
Copy link
Contributor

@nyurik nyurik commented Nov 9, 2023

This moves feature cleanup changes from #2023

In Cargo.toml, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new dep:* syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the ...?/... syntax instead of .../... -- as this both enabled an optional crate AND adds a feature to it. Now, it uses the "dep:...", "...?/..." syntax to prevent exposing crate name.

@seanmonstar
Copy link
Owner

Thanks for this PR! I'd been saving it for the breaking release that included the upgrade to hyper v1, which is now merged and 0.12 being prepared. Would you mind resolving the conflicts, and we can get this in?

@seanmonstar seanmonstar added this to the 0.12 milestone Mar 11, 2024
* In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.
@nyurik
Copy link
Contributor Author

nyurik commented Mar 12, 2024

thx for the ping, rebased, and reworked some feature conditionals

@seanmonstar seanmonstar changed the base branch from master to 0.12-dev March 12, 2024 13:43
Copy link
Owner

@seanmonstar seanmonstar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you so much!

@seanmonstar seanmonstar merged commit 1015d5f into seanmonstar:0.12-dev Mar 12, 2024
32 checks passed
seanmonstar pushed a commit that referenced this pull request Mar 19, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
seanmonstar pushed a commit that referenced this pull request Mar 19, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
seanmonstar pushed a commit that referenced this pull request Mar 19, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
seanmonstar pushed a commit that referenced this pull request Mar 20, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
seanmonstar pushed a commit that referenced this pull request Mar 20, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
seanmonstar pushed a commit that referenced this pull request Mar 20, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
@nyurik nyurik deleted the feature-cleanup branch July 31, 2024 14:43
Nutomic pushed a commit to Nutomic/reqwest that referenced this pull request Nov 7, 2024
In `Cargo.toml`, hide all optional dependencies as features

Currently, reqwest publishes all optional dependencies as features - which is usually not what is intended. Instead, the features should be explicitly declared, whereas optional features are enabled with the new `dep:*` syntax.

Note that I also had to fix a few conditional compilations which used optional crates rather than features as conditionals.

Also, note the use of the `...?/...` syntax instead of `.../...` -- as this both enabled an optional crate AND adds a feature to it.  Now, it uses the `"dep:...", "...?/..."` syntax to prevent exposing crate name.

Technically, this is *breaking change*, since people may have enabled some of these features accidentally. That's why we're including it in 0.12.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
B-breaking-change Blocked: breaking change.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants