Bump XDR and env to v23.0.0-rc.1.1#1467
Merged
Merged
Conversation
This is a minimum necessary SDK change to support protocol 23.
sisuresh
approved these changes
May 17, 2025
This was referenced May 18, 2025
github-merge-queue Bot
pushed a commit
to stellar/rs-soroban-env
that referenced
this pull request
May 19, 2025
### What Rename the host comparison method from check_same_env to is_same, changing it to return a boolean instead of a Result. ### Why The new name better reflects the method's purpose of being used by the SDK to compare two Hosts and determine if they in fact are the same underlying host implementation. The check function returns a result with the host assuming that there is in fact an error, whilst the is function returns a bool, merely providing information to the SDK so that the SDK can then decide in the context of its use whether there is an error or a change in behaviour is required. Close #1554 Related: - stellar/rs-soroban-sdk#1467 (comment)
sisuresh
reviewed
May 19, 2025
github-merge-queue Bot
pushed a commit
that referenced
this pull request
Jun 23, 2025
### What Add a `testutils` feature to `soroban-ledger-snapshot`, and use it to gate the functionality in ledger snapshots that uses the `soroban-env-host`'s `testutils` features. ### Why In #1467 the `soroban-ledger-snapshot` crate dependency on `soroban-env-host` was changed to include an always-enabled dependency on the `testutils` feature. This appears to have been done because the function `get_stored_entries` of the `Host` was changed from being always available, to only available in `testutils` mode. The `soroban-ledger-snapshot` crate uses the `get_stored_entries` function. A side-effect of of always pulling in the `soroban-env-host` is that the `soroban-ledger-snapshot` crate became incompatible with any project that also depends on the `soroban-sdk` without its `testutil` feature enabled. This is because the `soroban_env_host::EnvBase` trait type, which is implemented by the `soroban-sdk` crate, has functions that are required when the `testutil` feature is enabled. To resolve the above challenges with only changes to this repository the most straight-forward thing to do is to move the functionality in `soroban-ledger-snapshot` that now needs `testutils` in `soroban-env-host` behind a `testutils` feature as well, which `soroban-sdk` enables when it uses `soroban-ledger-snapshot`. ### Known Limitations Features on traits, like `EnvBase`, inherently create situations where dependencies can get stuck in situations where they are incompatible because another dep might be dependent on the trait in the opposite state. We should probably revisit `EnvBase`'s liberal use of features, breaking it up into separate traits. Rust features should always be, where possible, additively compatible. I've opened the following issue for us to explore that sometime: - stellar/rs-soroban-env#1570 We may also want to revisit whether some simple getters like `get_stored_entries` truly need to be gated behind a testutils flag. Features in general come at a cost in maintenance and rigidity. Typically features in Rust projects are used to reduce dependencies, but in `soroban-env-host` we are using it to limit features in different use cases. After #1467 and the change in this PR, some of the functionality in `soroban-ledger-snapshot` crate is unusable with the `Host`, unless the `Host` is being used in `testutils` mode. Today the only uses of the library that use that functionality is when the `soroban-sdk` is also being used with `testutils` enabled, but it is feasible that we may want to use the functionality in situations where it doesn't make sense to run the `Host` in `testutils` mode. This would probably mean changing the function in `soroban-env-host` that became testutils only, to be available without `testutils` again. We don't need it today, so I'm not proposing it today. cc @stellar/devx @stellar/contract-committers @fnando
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
What
Bump XDR and env to v23.0.0-rc.1.1
This is a minimum necessary SDK change to support protocol 23.
Why
Preparing for 23.0.0-rc.1 release
Known limitations
N/A