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

Upgrade mio-aio to 0.8.0 #6260

Closed
wants to merge 1 commit into from
Closed

Conversation

Darksonn
Copy link
Contributor

@Darksonn Darksonn commented Jan 1, 2024

This upgrades a test-only dependency for testing FreeBSD to 0.8.0. This allows us to remove an ignored CVE from our .cargo/audit.toml file. (See #4255 (comment).)

cc @asomers

@Darksonn Darksonn added A-tokio Area: The main tokio crate M-net Module: tokio/net A-ci Area: The continuous integration setup labels Jan 1, 2024
@Darksonn Darksonn requested a review from taiki-e January 1, 2024 11:52
@Darksonn
Copy link
Contributor Author

Darksonn commented Jan 1, 2024

This is more complicated than I thought it would be ...

@asomers
Copy link
Contributor

asomers commented Jan 1, 2024

Thanks for looking at this. I'm on vacation now, but I can help next week. Right now, i can't even see the ci failures, not on github's phone ui.

@Darksonn
Copy link
Contributor Author

Darksonn commented Jan 1, 2024

That would be very helpful!

The compilation failure is as follows:

error[E0432]: unresolved imports `mio_aio::AioCb`, `mio_aio::LioCb`
 --> tokio/tests/io_poll_aio.rs:4:15
  |
4 | use mio_aio::{AioCb, AioFsyncMode, LioCb};
  |               ^^^^^                ^^^^^ no `LioCb` in the root
  |               |
  |               no `AioCb` in the root

error[E0433]: failed to resolve: could not find `LioCbBuilder` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:313:36
    |
313 |         let mut builder = mio_aio::LioCbBuilder::with_capacity(1);
    |                                    ^^^^^^^^^^^^ could not find `LioCbBuilder` in `mio_aio`

error[E0433]: failed to resolve: could not find `LioOpcode` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:319:22
    |
319 |             mio_aio::LioOpcode::LIO_WRITE,
    |                      ^^^^^^^^^ could not find `LioOpcode` in `mio_aio`

error[E0433]: failed to resolve: could not find `LioCbBuilder` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:339:37
    |
339 |         let mut builder0 = mio_aio::LioCbBuilder::with_capacity(1);
    |                                     ^^^^^^^^^^^^ could not find `LioCbBuilder` in `mio_aio`

error[E0433]: failed to resolve: could not find `LioOpcode` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:345:22
    |
345 |             mio_aio::LioOpcode::LIO_WRITE,
    |                      ^^^^^^^^^ could not find `LioOpcode` in `mio_aio`

error[E0433]: failed to resolve: could not find `LioCbBuilder` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:357:37
    |
357 |         let mut builder1 = mio_aio::LioCbBuilder::with_capacity(1);
    |                                     ^^^^^^^^^^^^ could not find `LioCbBuilder` in `mio_aio`

error[E0433]: failed to resolve: could not find `LioOpcode` in `mio_aio`
   --> tokio/tests/io_poll_aio.rs:363:22
    |
363 |             mio_aio::LioOpcode::LIO_WRITE,
    |                      ^^^^^^^^^ could not find `LioOpcode` in `mio_aio`

Some errors have detailed explanations: E0432, E0433.
For more information about an error, try `rustc --explain E0432`.
error: could not compile `tokio` (test "io_poll_aio") due to 7 previous errors
warning: build failed, waiting for other jobs to finish...

Exit status: 101

asomers added a commit to asomers/tokio that referenced this pull request Jan 6, 2024
This is a test-only dependency.  The main reason for the update is to
avoid transitively depending on a Nix version with a CVE.

mio-aio 0.8.0 has a substantially different API than 0.7.0.  Notably, it
no longer includes any lio_listio functionality.  So to test Tokio's
handling of EVFILT_LIO events we must go low-level and call
libc::lio_listio directly.

Supersedes tokio-rs#6260
@asomers asomers mentioned this pull request Jan 6, 2024
@Darksonn Darksonn closed this Jan 6, 2024
@Darksonn Darksonn deleted the alice/update-mio-aio-0.8.0 branch January 6, 2024 10:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-ci Area: The continuous integration setup A-tokio Area: The main tokio crate M-net Module: tokio/net
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants