Summary
Returns typed error if Option is None, used in entrypoints to avoid panics.
Background
This change improves the day-to-day experience for the people who consume this code (operators, downstream contracts, frontend engineers, support). It is not a strict bug, but the current behaviour forces workarounds and the proposed change removes them.
Acceptance criteria
Implementation hints
- Keep the public API surface backwards-compatible if possible. If a breaking change is unavoidable, document the migration step.
- Land any new constant in a single place (
config/, consts.rs, or the equivalent) and re-use it everywhere.
- Update the relevant
docs/ page in the same PR so reviewers see the docs change together with the code change.
- Add or update the corresponding test so the new behaviour is locked in.
Repo-specific notes
- This is a Soroban contract crate. Run
cargo build --target wasm32-unknown-unknown --release to verify the change still builds for WASM.
- Run
cargo test -p <package> for the affected crate, and cargo clippy --workspace --all-targets -- -D warnings before pushing.
- Keep
#![no_std] discipline: do not introduce std:: calls; use soroban_sdk primitives.
Out of scope
- Unrelated refactors in adjacent files.
- Stylistic-only changes (formatting, renaming) that are not required by the fix.
- Anything beyond the acceptance criteria above; surface follow-ups as separate issues.
How to claim and submit
- Comment on this issue saying you'd like to take it on; wait for a maintainer to assign you (avoids duplicated effort).
- Open a PR that references this issue (
Closes #<this-issue>).
- Make sure CI is green and request review from a
CODEOWNERS maintainer.
- PRs that close this issue and pass review may qualify for a reward — see the
MAYBE REWARDED label and the GrantFox OSS campaign page.
Category: enhancement · Campaign: GrantFox OSS · Official Campaign · Maybe Rewarded
Summary
Returns typed error if Option is None, used in entrypoints to avoid panics.
Background
This change improves the day-to-day experience for the people who consume this code (operators, downstream contracts, frontend engineers, support). It is not a strict bug, but the current behaviour forces workarounds and the proposed change removes them.
Acceptance criteria
Closes #<this-issue>.Implementation hints
config/,consts.rs, or the equivalent) and re-use it everywhere.docs/page in the same PR so reviewers see the docs change together with the code change.Repo-specific notes
cargo build --target wasm32-unknown-unknown --releaseto verify the change still builds for WASM.cargo test -p <package>for the affected crate, andcargo clippy --workspace --all-targets -- -D warningsbefore pushing.#![no_std]discipline: do not introducestd::calls; usesoroban_sdkprimitives.Out of scope
How to claim and submit
Closes #<this-issue>).CODEOWNERSmaintainer.MAYBE REWARDEDlabel and the GrantFox OSS campaign page.Category:
enhancement· Campaign: GrantFox OSS · Official Campaign · Maybe Rewarded