-
-
Notifications
You must be signed in to change notification settings - Fork 318
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
Make gix crates ready for automatic cfg checking #1123
Conversation
The CI failures are related to some new clippy lints and the nightly feature activation being now tied to an actual feature making them fail with Let me know how you want to proceed? |
Thanks a lot for contributing the preparation for the upcoming
This whole crate is a hack, unfortunately, so that there is a blocking version of the crate that can be used internally, without having the overhead of a real copy. Thus, I don't think one should add anything else to it - it fulfils its purpose and ideally won't be used. I hope that once there are new async-related features, it can be removed entirely. Or in other words,
It's a very nice gesture, but I think if it should be useful it needs to be made so it can't actually fail a build. Ideally, it provides a preview of what's to come, but I can't have failures on a daily basis because new lint was added. Right now, I see this every 6 weeks or so when a new stable release trickles down, and that seems good enough.
Everything you think would work also works for me. There is just this one requirement that |
Otherwise there would be many unexpected_cfgs warnings for async-io coming from the gix-packetline sources.
Regarding the changes to
Completely agree, it's unreasonable to expect someone to block on nightly. My idea is to run the job as normal but to mark it as not failling, that's why I added Changed to
Seems to work and it-fact it was even used before, so. |
Let's remove nightly, it's clean and will definitely work. It's also only tangentially related to this PR, so I think it's the right thing to do. I will probably just do that myself before merging, so nothing left to be done here. Thanks again for your help, it's much appreciated! |
And even if it was advisory only, what good does it do if nobody looks at it? And I know myself :D.
@@ -12,8 +12,13 @@ include = ["src/**/*", "LICENSE-*"] | |||
[lib] | |||
doctest = false | |||
|
|||
[features] |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
A great catch, thank you!
According to whom is it an anti-pattern? I've not seen any talk of that and found it much better than using features. |
I meant that with check-cfg+Cargo it's a bit of "anti-pattern" since enabling the |
Its not sufficient with I wouldn't classify that as an anti-pattern but a relevant use case for us to consider. |
This PR makes the necessary changes to make gitoxide crates ready for
-Zcheck-cfg
(automatic cfgs checking) being enabled by default.--cfg docsrs
and#[cfg_attr(docsrs, ...)]
which are an anti-pattern and simply use the already existing featuredocument-features
.serde
feature ingix-fs
and remove a dead code from the now non-existinglean-cli
feature.async-io
feature togix-packetline-blocking
since being a symlink togix-packetline
it needs to have all the feature of the former.Maybe instead of adding the
async-io
feature we could allow the lint forgix-packetline-blocking
?lint-nightly
to run nightly tools, in particularcargo check -Zcheck-cfg
.