-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fixing Ledger 1.1.10 interacting with whitelisted fee token contracts (…
…#395) There was a bug where ledgers would return a INVALID DATA error when trying to transfer or interactive with a contract of one of the whitelisted gas fee tokens. or using a gas token to pay for gas. This occured while checking if the token was known in order to display human readble data while confirming on the ledger. The legacy 1.1.10 version of ledger app uses an older blob of signed data. it seems in this case the encoded data should NOT be prefixed by 0x. while in the newer it should be. this was not obvious and as automated tests are difficult when interacting with hw devices was missed. turned off test for cip66. Possibly we will remove later. ## related Issues fixes #394 fixes #353 <!-- start pr-codex --> --- ## PR-Codex overview This PR focuses on fixing issues related to token transfers and gas currency handling in the `celo` ecosystem, particularly with the `@celo/celocli` and `@celo/wallet-ledger` packages. It also improves error messages and adds a new method for providing token information. ### Detailed summary - Updated error messages in `packages/cli/src/transfer-stable-base.ts` for clarity on transfer affordability. - Fixed token information handling in `packages/sdk/wallets/wallet-ledger/src/ledger-signer.ts`. - Added `provideERC20TokenInformation` method to `LedgerSigner`. - Improved tests in `packages/sdk/wallets/wallet-ledger/src/ledger-wallet.test.ts` with mock implementations and inline snapshots. - Updated test suite to skip certain tests related to `cip66`. > ✨ Ask PR-Codex anything about this PR by commenting with `/codex {your question}` <!-- end pr-codex -->
- Loading branch information
Showing
7 changed files
with
65 additions
and
6 deletions.
There are no files selected for viewing
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@celo/wallet-ledger': patch | ||
--- | ||
|
||
Fix issue where ledger running celo firmware app 1.1.10 could not send fee token transactions or perform and interactions with those contracts |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@celo/celocli': patch | ||
--- | ||
|
||
Fix incorrect message where the transfered token was used as gas token in the messaging but not in actuality |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,5 @@ | ||
--- | ||
'@celo/celocli': patch | ||
--- | ||
|
||
Fix Transfering, exchanging cusd (and other fee tokens) and or using gasCurrency flag with ledger devices prior to 1.2 |
This file contains 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -92,3 +92,4 @@ package.json-e | |
gha-creds-*.json | ||
transactions.json | ||
packages/sdk/metadata-claims/lib | ||
packages/cli/key |
This file contains 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
This file contains 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
This file contains 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