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

Minor versions do not support backwards compatibility #2479

Open
MatthewLM opened this issue Jan 3, 2025 · 1 comment
Open

Minor versions do not support backwards compatibility #2479

MatthewLM opened this issue Jan 3, 2025 · 1 comment
Labels
awaiting Waiting for responses, PR, further discussions, upstream release, etc bug Something isn't working

Comments

@MatthewLM
Copy link

Describe the bug

If the package version is specified using a caret in pubspec.yaml and the minor version is updated, an error will be produced similar to:

Bad state: flutter_rust_bridge's codegen version (2.6.0) should be the same as runtime version (2.7.0)

Minor version numbers should allow backwards compatibility if semantic versioning is followed.

Steps to reproduce

Self evident

Logs

No need for logs

Expected behavior

No response

Generated binding code

No response

OS

No response

Version of flutter_rust_bridge_codegen

No response

Flutter info

No response

Version of clang++

No response

Additional context

No response

@MatthewLM MatthewLM added the bug Something isn't working label Jan 3, 2025
@fzyzcjy
Copy link
Owner

fzyzcjy commented Jan 3, 2025

It supports backward compatibility in the sense that, the user code should be able to run when upgrading from 2.6.0 to 2.7.0 without issues.

For your question, it is that you need to keep Rust flutter_rust_bridge in sync with Dart flutter_rust_bridge version. This is usually automatically done when running flutter_rust_bridge_codegen.

@fzyzcjy fzyzcjy added the awaiting Waiting for responses, PR, further discussions, upstream release, etc label Jan 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting Waiting for responses, PR, further discussions, upstream release, etc bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants