Conversation
### What changed? Why?
There was a bug in the from_model function in asset.py. On the backend
side, any asset id is checksummed before retrieving its details, and
when it returns a response to the SDK, its asset id is also checksummed.
When a user enters a non-checksummed address, they will get an error
since those two asset ids are not equivalent.
This change will allow users to use non-checksummed addresses without
getting erroneous errors in their workflow.
Before:
```
>>> wallet.balance('0x8309fbdf021edf768dc13195741940ba544dea98')
ArgumentError: Unsupported asset ID: 0x8309fbdf021edf768dc13195741940ba544dea98
```
After:
```
>>> wallet.balance('0x8309fbdf021edf768dc13195741940ba544dea98')
0.0
```
#### Qualified Impact
This change should not be a breaking change for the SDK. The same logic
of the check for asset ids exists, but with the normalization of cases,
it prevents the bug of non-checksummed addresses and checksummed
addresses being considered as unequal.
What changed? Why? The package versions and changelog were updated to reflect the upcoming release of SDK version v0.16.0. Qualified Impact The impact of this change will update the SDK to the latest version which includes one bug fix. In the case of any errors or failures, the best approach would be to rollback to v0.14.0 and re-release a new version after fixing any errors.
✅ Heimdall Review Status
|
jazz-cb
approved these changes
Jan 28, 2025
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 changed? Why?
A bug fix for non-checksummed addresses was added in this release. The change was made to prevent users from encountering an "unsupported asset" error when using non-checksummed addresses for assets.
Qualified Impact
This component mainly affects the assets class, where the asset id gets normalized. If there are any issues, it should be safe to revert back to v0.14.0 and then fix any errors before re-releasing.