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

New release breaks callers of the Error derive if it came from a re-export from another crate #241

Closed
NiseVoid opened this issue Jul 7, 2023 · 2 comments · Fixed by #242

Comments

@NiseVoid
Copy link

NiseVoid commented Jul 7, 2023

Hello, the new release of thiserror seems to have broken something. A game engine called bevy re-exports thiserror in a bevy_utils crate, when the code is then called in other places it fails to compile on the newest release because it calls thiserror::__private when the path it is available at would be bevy_utils::thiserror::_private. This results in compilation errors, for example this CI run: https://github.com/Jondolf/bevy_xpbd/actions/runs/5481101314/jobs/9985014733#step:4:293
I'm not quite sure what the correct solution here is, but I think calling the macros from a re-export is a valid usecase that should work as intended

@NiseVoid NiseVoid changed the title New release breaks callers of the Error derive if it came from a reimport from another crate New release breaks callers of the Error derive if it came from a re-export from another crate Jul 7, 2023
@NiseVoid
Copy link
Author

NiseVoid commented Jul 7, 2023

The relevant line of code that's hitting the error:
https://github.com/bevyengine/bevy/blob/v0.10.1/crates/bevy_ecs/src/schedule/schedule.rs#L1582

As you can see, nothing too strange here, just a derive Error. But it comes from bevy_utils::thiserror::Error, so there is no thiserror in scope

@dtolnay
Copy link
Owner

dtolnay commented Jul 7, 2023

Fixed in 1.0.43.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants