Skip to content

Conversation

sbernauer
Copy link
Member

@sbernauer sbernauer commented Nov 28, 2024

Description

Fixes #916
Part of stackabletech/issues#677

Note: I ran cargo update to get the changes.

Definition of Done Checklist

  • Not all of these items are applicable to all PRs, the author should update this template to only leave the boxes in that are relevant
  • Please make sure all these things are done and tick the boxes
# Author
- [ ] Changes are OpenShift compatible
- [ ] CRD changes approved
- [ ] Integration tests passed (for non trivial changes)
# Reviewer
- [ ] Code contains useful comments
- [ ] (Integration-)Test cases added
- [ ] Documentation added or updated
- [ ] Changelog updated
- [ ] Cargo.toml only contains references to git tags (not specific commits or branches)
# Acceptance
- [ ] Feature Tracker has been updated
- [ ] Proper release label has been added

@adwk67
Copy link
Member

adwk67 commented Nov 28, 2024

I'm getting some test failures on compile:
test tests/default/fail/skip_from_all.rs ... mismatch

@sbernauer
Copy link
Member Author

Can you please try rustup component add rust-src and re-run?
CC @Techassi @NickLarsenNZ

@sbernauer
Copy link
Member Author

(It's unrelated to this PR, main should fail for you as well)

@adwk67
Copy link
Member

adwk67 commented Nov 28, 2024

rustup component add rust-src

No change. I'm running the tests and get

ACTUAL OUTPUT:
┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈┈
error[E0308]: mismatched types
  --> tests/default/fail/skip_from_version.rs:23:32
   |
23 |     let foo_v1 = v1::Foo::from(foo_v1beta1);
   |                  ------------- ^^^^^^^^^^^ expected `main::v1::Foo`, found `v1beta1::Foo`
   |                  |
   |                  arguments to this function are incorrect
   |
   = note: `v1beta1::Foo` and `main::v1::Foo` have similar names, but are actually distinct types
note: `v1beta1::Foo` is defined in module `crate::main::v1beta1` of the current crate
  --> tests/default/fail/skip_from_version.rs:4:5
   |
4  | /     #[versioned(
5  | |         version(name = "v1alpha1"),
6  | |         version(name = "v1beta1", skip(from)),
7  | |         version(name = "v1")
8  | |     )]
   | |______^
note: `main::v1::Foo` is defined in module `crate::main::v1` of the current crate
  --> tests/default/fail/skip_from_version.rs:4:5
   |
4  | /     #[versioned(
5  | |         version(name = "v1alpha1"),
6  | |         version(name = "v1beta1", skip(from)),
7  | |         version(name = "v1")
8  | |     )]
   | |______^
note: associated function defined here
  --> $RUST/core/src/convert/mod.rs
   |
   |     fn from(value: T) -> Self;
   |        ^^^^
   = note: this error originates in the attribute macro `versioned` (in Nightly builds, run with -Z macro-backtrace for more info)

@Techassi
Copy link
Member

Yes @adwk67 errors are unrelated to the change. Make sure you have the rust-src component installed and use the latest Rust toolchain (specified in rust-toolchain.toml). Also make sure to run cargo clean to remove any cached files.

Copy link
Member

@Techassi Techassi left a comment

Choose a reason for hiding this comment

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

Please add an entry in the changelog. Also mention how you bumped the dependency in the PR description, so cargo update -p rustls for example.

@adwk67
Copy link
Member

adwk67 commented Nov 28, 2024

Yes @adwk67 errors are unrelated to the change. Make sure you have the rust-src component installed and use the latest Rust toolchain (specified in rust-toolchain.toml). Also make sure to run cargo clean to remove any cached files.

I actually had to remove the toolchain component with:
rustup component remove rust-src --toolchain 1.82.0
and then all tests were green.

@Techassi
Copy link
Member

I actually had to remove the toolchain component

Mhm... That's curious. Not quite sure why that's the case. I can investigate this a little more if we see the need for it.

@sbernauer
Copy link
Member Author

AFAIK the Cargo.lock is only relevant to this specific repo, so users of this crates will never even notice this change.
However, I still added a changelog entry as security stuff sounds good :)

@sbernauer sbernauer requested a review from Techassi November 28, 2024 08:37
@Techassi Techassi changed the title Bump rustls from 0.23.15 to 0.23.19 to fix RUSTSEC-2024-0399 chore: Bump rustls from 0.23.15 to 0.23.19 to fix RUSTSEC-2024-0399 Nov 28, 2024
Co-authored-by: Techassi <git@techassi.dev>
@sbernauer sbernauer requested a review from Techassi November 28, 2024 09:42
@sbernauer sbernauer added this pull request to the merge queue Nov 28, 2024
Merged via the queue into main with commit af57d34 Nov 28, 2024
8 of 10 checks passed
@sbernauer sbernauer deleted the chore/bump-rustls branch November 28, 2024 10:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

RUSTSEC-2024-0399: rustls network-reachable panic in Acceptor::accept
3 participants