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

Determine msrv for every standalone bevy_* crate. #13211

Merged
merged 1 commit into from
May 13, 2024

Conversation

Brezak
Copy link
Contributor

@Brezak Brezak commented May 3, 2024

Objective

As was pointed out in #13183, bevy_mikktspace is missing it's msrv from it Cargo.toml. This promted me to check the msrv of every bevy_* crate. Closes #13183.

Solution

  • Call cargo check with different rust versions on every bevy crate until it doesn't complain.
  • Write down the rust version cargo check started working.

Testing

  • Install cargo-msrv.
  • Run cargo msrv verify.
  • Rejoice.

Changelog

Every published bevy crate now specifies a MSRV. If your rust toolchain isn't at least version 1.77.0 You'll likely not be able to compile most of bevy.

Migration Guide

If your rust toolchain is bellow version`1.77.0, update.

@Brezak
Copy link
Contributor Author

Brezak commented May 3, 2024

I spent too much time on this graph. I need it immortalized somewhere.

stateDiagram-v2

bevy_dev_tools --> bevy_app
bevy_dev_tools --> bevy_asset
bevy_dev_tools --> bevy_color
bevy_dev_tools --> bevy_core
bevy_dev_tools --> bevy_core_pipeline
bevy_dev_tools --> bevy_diagnostic
bevy_dev_tools --> bevy_ecs
bevy_dev_tools --> bevy_gizmos
bevy_dev_tools --> bevy_hierarchy
bevy_dev_tools --> bevy_input
bevy_dev_tools --> bevy_math
bevy_dev_tools --> bevy_reflect
bevy_dev_tools --> bevy_render
bevy_dev_tools --> bevy_text
bevy_dev_tools --> bevy_time
bevy_dev_tools --> bevy_transform
bevy_dev_tools --> bevy_ui
bevy_dev_tools --> bevy_utils
bevy_dev_tools --> bevy_window

bevy --> bevy_internal

bevy_internal --> bevy_a11y
bevy_internal --> bevy_animation
bevy_internal --> bevy_app
bevy_internal --> bevy_asset
bevy_internal --> bevy_audio
bevy_internal --> bevy_color
bevy_internal --> bevy_core
bevy_internal --> bevy_core_pipeline
bevy_internal --> bevy_derive
bevy_internal --> bevy_diagnostic
bevy_internal --> bevy_ecs
bevy_internal --> bevy_gilrs
bevy_internal --> bevy_gizmos
bevy_internal --> bevy_gltf
bevy_internal --> bevy_hierarchy
bevy_internal --> bevy_input
bevy_internal --> bevy_log
bevy_internal --> bevy_math
bevy_internal --> bevy_pbr
bevy_internal --> bevy_ptr
bevy_internal --> bevy_reflect
bevy_internal --> bevy_render
bevy_internal --> bevy_scene
bevy_internal --> bevy_sprite
bevy_internal --> bevy_tasks
bevy_internal --> bevy_text
bevy_internal --> bevy_time
bevy_internal --> bevy_transform
bevy_internal --> bevy_ui
bevy_internal --> bevy_utils
bevy_internal --> bevy_window
bevy_internal --> bevy_winit

bevy_winit --> bevy_a11y
bevy_winit --> bevy_app
bevy_winit --> bevy_derive
bevy_winit --> bevy_ecs
bevy_winit --> bevy_hierarchy
bevy_winit --> bevy_input
bevy_winit --> bevy_log
bevy_winit --> bevy_math
bevy_winit --> bevy_reflect
bevy_winit --> bevy_tasks
bevy_winit --> bevy_utils
bevy_winit --> bevy_window

bevy_ui --> bevy_a11y
bevy_ui --> bevy_app
bevy_ui --> bevy_asset
bevy_ui --> bevy_color
bevy_ui --> bevy_core_pipeline
bevy_ui --> bevy_derive
bevy_ui --> bevy_ecs
bevy_ui --> bevy_hierarchy
bevy_ui --> bevy_input
bevy_ui --> bevy_math
bevy_ui --> bevy_reflect
bevy_ui --> bevy_render
bevy_ui --> bevy_sprite
bevy_ui --> bevy_text
bevy_ui --> bevy_transform
bevy_ui --> bevy_utils
bevy_ui --> bevy_window

bevy_text --> bevy_app
bevy_text --> bevy_asset
bevy_text --> bevy_color
bevy_text --> bevy_ecs
bevy_text --> bevy_math
bevy_text --> bevy_reflect
bevy_text --> bevy_render
bevy_text --> bevy_sprite
bevy_text --> bevy_transform
bevy_text --> bevy_utils
bevy_text --> bevy_window

bevy_gltf --> bevy_animation
bevy_gltf --> bevy_app
bevy_gltf --> bevy_asset
bevy_gltf --> bevy_color
bevy_gltf --> bevy_core
bevy_gltf --> bevy_core_pipeline
bevy_gltf --> bevy_ecs
bevy_gltf --> bevy_hierarchy
bevy_gltf --> bevy_math
bevy_gltf --> bevy_pbr
bevy_gltf --> bevy_reflect
bevy_gltf --> bevy_render
bevy_gltf --> bevy_scene
bevy_gltf --> bevy_tasks
bevy_gltf --> bevy_transform
bevy_gltf --> bevy_utils

bevy_scene --> bevy_app
bevy_scene --> bevy_asset
bevy_scene --> bevy_derive
bevy_scene --> bevy_ecs
bevy_scene --> bevy_hierarchy
bevy_scene --> bevy_reflect
bevy_scene --> bevy_render
bevy_scene --> bevy_transform
bevy_scene --> bevy_utils

bevy_gizmos --> bevy_app
bevy_gizmos --> bevy_asset
bevy_gizmos --> bevy_color
bevy_gizmos --> bevy_core_pipeline
bevy_gizmos --> bevy_ecs
bevy_gizmos --> bevy_gizmos_macros
bevy_gizmos --> bevy_math
bevy_gizmos --> bevy_pbr
bevy_gizmos --> bevy_reflect
bevy_gizmos --> bevy_sprite
bevy_gizmos --> bevy_time
bevy_gizmos --> bevy_transform
bevy_gizmos --> bevy_utils

bevy_sprite --> bevy_app
bevy_sprite --> bevy_asset
bevy_sprite --> bevy_color
bevy_sprite --> bevy_core_pipeline
bevy_sprite --> bevy_derive
bevy_sprite --> bevy_ecs
bevy_sprite --> bevy_math
bevy_sprite --> bevy_reflect
bevy_sprite --> bevy_render
bevy_sprite --> bevy_transform
bevy_sprite --> bevy_utils

bevy_pbr --> bevy_app
bevy_pbr --> bevy_asset
bevy_pbr --> bevy_color
bevy_pbr --> bevy_core_pipeline
bevy_pbr --> bevy_derive
bevy_pbr --> bevy_ecs
bevy_pbr --> bevy_math
bevy_pbr --> bevy_reflect
bevy_pbr --> bevy_render
bevy_pbr --> bevy_transform
bevy_pbr --> bevy_utils
bevy_pbr --> bevy_window

bevy_gizmos_macros --> bevy_macro_utils

bevy_gilrs --> bevy_app
bevy_gilrs --> bevy_ecs
bevy_gilrs --> bevy_input
bevy_gilrs --> bevy_time
bevy_gilrs --> bevy_utils

bevy_input --> bevy_app
bevy_input --> bevy_ecs
bevy_input --> bevy_math
bevy_input --> bevy_reflect
bevy_input --> bevy_utils

bevy_core_pipeline --> bevy_app
bevy_core_pipeline --> bevy_asset
bevy_core_pipeline --> bevy_color
bevy_core_pipeline --> bevy_core
bevy_core_pipeline --> bevy_derive
bevy_core_pipeline --> bevy_ecs
bevy_core_pipeline --> bevy_math
bevy_core_pipeline --> bevy_reflect
bevy_core_pipeline --> bevy_render
bevy_core_pipeline --> bevy_transform
bevy_core_pipeline --> bevy_utils


bevy_audio --> bevy_app
bevy_audio --> bevy_asset
bevy_audio --> bevy_derive
bevy_audio --> bevy_ecs
bevy_audio --> bevy_hierarchy
bevy_audio --> bevy_math
bevy_audio --> bevy_reflect
bevy_audio --> bevy_transform
bevy_audio --> bevy_utils

bevy_animation --> bevy_app
bevy_animation --> bevy_asset
bevy_animation --> bevy_color
bevy_animation --> bevy_core
bevy_animation --> bevy_derive
bevy_animation --> bevy_ecs
bevy_animation --> bevy_hierarchy
bevy_animation --> bevy_log
bevy_animation --> bevy_math
bevy_animation --> bevy_reflect
bevy_animation --> bevy_render
bevy_animation --> bevy_time
bevy_animation --> bevy_transform
bevy_animation --> bevy_utils

bevy_render --> bevy_app
bevy_render --> bevy_asset
bevy_render --> bevy_color
bevy_render --> bevy_core
bevy_render --> bevy_derive
bevy_render --> bevy_diagnostic
bevy_render --> bevy_ecs
bevy_render --> bevy_encase_derive
bevy_render --> bevy_hierarchy
bevy_render --> bevy_math
bevy_render --> bevy_mikktspace
bevy_render --> bevy_reflect
bevy_render --> bevy_render_macros
bevy_render --> bevy_tasks
bevy_render --> bevy_time
bevy_render --> bevy_transform
bevy_render --> bevy_utils
bevy_render --> bevy_window


bevy_window --> bevy_a11y
bevy_window --> bevy_app
bevy_window --> bevy_ecs
bevy_window --> bevy_math
bevy_window --> bevy_reflect
bevy_window --> bevy_utils

bevy_transform --> bevy_app
bevy_transform --> bevy_ecs
bevy_transform --> bevy_hierarchy
bevy_transform --> bevy_math
bevy_transform --> bevy_reflect
%%dev deps
bevy_transform --> bevy_math %% here twice
bevy_transform --> bevy_tasks

bevy_render_macros --> bevy_macro_utils

bevy_encase_derive --> bevy_macro_utils

bevy_diagnostic --> bevy_app
bevy_diagnostic --> bevy_core
bevy_diagnostic --> bevy_ecs
bevy_diagnostic --> bevy_time
bevy_diagnostic --> bevy_utils

bevy_time --> bevy_app
bevy_time --> bevy_ecs
bevy_time --> bevy_reflect
bevy_time --> bevy_utils

bevy_hierarchy --> bevy_app
bevy_hierarchy --> bevy_core
bevy_hierarchy --> bevy_ecs
bevy_hierarchy --> bevy_reflect
bevy_hierarchy --> bevy_utils

bevy_color --> bevy_math
bevy_color --> bevy_reflect


bevy_asset --> bevy_app
bevy_asset --> bevy_asset_macros
bevy_asset --> bevy_ecs
bevy_asset --> bevy_reflect
bevy_asset --> bevy_tasks
bevy_asset --> bevy_utils
%%dev deps
bevy_asset --> bevy_core
bevy_asset --> bevy_log

bevy_log --> bevy_app
bevy_log --> bevy_ecs
bevy_log --> bevy_utils

bevy_core --> bevy_app
bevy_core --> bevy_ecs
bevy_core --> bevy_reflect
bevy_core --> bevy_tasks
bevy_core --> bevy_utils

bevy_asset_macros --> bevy_macro_utils

bevy_a11y --> bevy_app
bevy_a11y --> bevy_derive
bevy_a11y --> bevy_ecs

bevy_app --> bevy_derive
bevy_app --> bevy_ecs
bevy_app --> bevy_reflect
bevy_app --> bevy_tasks
bevy_app --> bevy_utils


bevy_ecs --> bevy_ecs_macros
bevy_ecs --> bevy_ptr
bevy_ecs --> bevy_reflect
bevy_ecs --> bevy_tasks

bevy_tasks --> bevy_utils

bevy_reflect --> bevy_math
bevy_reflect --> bevy_ptr
bevy_reflect --> bevy_reflect_derive
bevy_reflect --> bevy_utils

bevy_utils --> bevy_utils_proc_macros

bevy_reflect_derive --> bevy_macro_utils

bevy_ecs_macros --> bevy_macro_utils

bevy_derive --> bevy_macro_utils

bevy_dylib --> bevy_internal

bevy_dynamic_plugin --> bevy_app

state "bevy_ptr 1.65.0" as bevy_ptr
state "bevy_macro_utils 1.70.0" as bevy_macro_utils
state "bevy_utils_proc_macros 1.70.0" as bevy_utils_proc_macros
state "bevy_utils 1.76.0" as bevy_utils
state "bevy_gizmos_macros 1.70.0" as bevy_gizmos_macros
state "bevy_render_macros 1.70.0" as bevy_render_macros
state "bevy_encase_derive 1.70.0" as bevy_encase_derive
state "bevy_render 1.77.0" as bevy_render
state "bevy_asset_macros 1.70.0" as bevy_asset_macros
state "bevy_asset 1.77.0" as bevy_asset
state "bevy_ecs_macros 1.70.0" as bevy_ecs_macros
state "bevy_ecs 1.77.0" as bevy_ecs
state "bevy_reflect_derive 1.70.0" as bevy_reflect_derive
state "bevy_reflect 1.76.0" as bevy_reflect
state "bevy_math 1.68.2" as bevy_math
state "bevy_tasks 1.70.0" as bevy_tasks
state "bevy_derive 1.70.0" as bevy_derive
state "bevy_app 1.76.0" as bevy_app
state "bevy_core 1.76.0" as bevy_core
state "bevy_hierarchy 1.76.0" as bevy_hierarchy
state "bevy_log 1.76.0" as bevy_log
state "bevy_gilrs 1.76.0" as bevy_gilrs
state "bevy_input 1.76.0" as bevy_input
state "bevy_a11y 1.76.0" as bevy_a11y
state "bevy_time 1.76.0" as bevy_time
state "bevy_mikktspace 1.76.0" as bevy_mikktspace
state "bevy_diagnostic 1.76.0" as bevy_diagnostic
state "bevy_color 1.76.0" as bevy_color
state "bevy_transform 1.76.0" as bevy_transform
state "bevy_window 1.76.0" as bevy_window
state "bevy_winit 1.76.0" as bevy_winit
state "bevy_core_pipeline 1.77.0" as bevy_core_pipeline
state "bevy_audio 1.77.0" as bevy_audio
state "bevy_scene 1.77.0" as bevy_scene
state "bevy_sprite 1.77.0" as bevy_sprite
state "bevy_text 1.77.0" as bevy_text
state "bevy_gizmos 1.77.0" as bevy_gizmos
state "bevy_ui 1.77.0" as bevy_ui
state "bevy_pbr 1.77.0" as bevy_pbr
state "bevy_animation 1.77.0" as bevy_animation
state "bevy_gltf 1.77.0" as bevy_gltf
state "bevy_dev_tools 1.77.0" as bevy_dev_tools
state "bevy_internal 1.77.0" as bevy_internal
state "bevy 1.77.0" as bevy
state "bevy_dylib 1.77.0" as bevy_dylib
state "bevy_dynamic_plugin 1.77.0" as bevy_dynamic_plugin

Every bevy workspace crate, it's bevy dependencies and it's msrv.

@mockersf
Copy link
Member

mockersf commented May 3, 2024

generally not in favor of this. It doesn't make sense to track a MSRV for some of those crate as they don't really make sense as a standalone crates, so it just means we will have more things to maintain that don't bring value

@alice-i-cecile alice-i-cecile added C-Code-Quality A section of code that is hard to understand or change S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it A-Cross-Cutting Impacts the entire engine X-Controversial There is active debate or serious implications around merging this PR labels May 3, 2024
Copy link
Member

@alice-i-cecile alice-i-cecile left a comment

Choose a reason for hiding this comment

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

Yeah, I think I agree with @mockersf here on reflection. The "standalone" crates for Bevy are:

  • bevy_ecs
  • bevy_reflect
  • bevy_math
  • bevy_color

Those can have an MSRV listed, but the others should not.

Updating it for bevy_mikktspace seems fine though: we definitely shouldn't report incroorect information.

@alice-i-cecile alice-i-cecile added S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged and removed S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it labels May 3, 2024
@Brezak
Copy link
Contributor Author

Brezak commented May 3, 2024

I've removed the msrv specification from everything but

  • bevy
  • bevy_color
  • bevy_ecs
  • bevy_math
  • bevy_mikktspace
  • bevy_reflect
    I kept bevy_mikktspace because we specify the MSRV in the README.md.

@alice-i-cecile alice-i-cecile added S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it and removed X-Controversial There is active debate or serious implications around merging this PR S-Waiting-on-Author The author needs to make changes or address concerns before this can be merged labels May 3, 2024
@mockersf
Copy link
Member

mockersf commented May 3, 2024

If this is not checked in CI, it will just become unsynced and useless.

We already check the MSRV for the Bevy crate, it should be added for the others.

I'm still not convinced this bring enough value to be worth the CI time though

@BD103
Copy link
Member

BD103 commented May 3, 2024

rust-version is inheritable. You can add rust-version.workspace = true to all crates, then just update the root Cargo.toml. This wouldn't need testing in CI because we already specify it for bevy.

The only crate that would need to differ from this is probably bevy_mikktspace, which is not really going to be updated and may be useful in the ecosystem.

@Brezak
Copy link
Contributor Author

Brezak commented May 3, 2024

If this is not checked in CI, it will just become unsynced and useless.

We already check the MSRV for the Bevy crate, it should be added for the others.

I'm still not convinced this bring enough value to be worth the CI time though

We're kind checking the per package msrv already. In (1.77.0-1.78.0) clippy gained a lint that checks function msrv. Only thing that isn't happening is we're not checking for msrv incompatible language constructs.

@alice-i-cecile alice-i-cecile changed the title Determine msrv for every bevy_* crate. Determine msrv for every standalone bevy_* crate. May 13, 2024
@alice-i-cecile alice-i-cecile added this pull request to the merge queue May 13, 2024
Merged via the queue into bevyengine:main with commit cbda71c May 13, 2024
32 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-Cross-Cutting Impacts the entire engine C-Code-Quality A section of code that is hard to understand or change S-Ready-For-Final-Review This PR has been approved by the community. It's ready for a maintainer to consider merging it
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add rust-version field to bevy_mikktspace
5 participants