-
Notifications
You must be signed in to change notification settings - Fork 15
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
Crypto-to-fiat: Resolve edge cases with liquidation addresses #2794
Conversation
1903d2e
to
722b1bd
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
When trying to test this, loading the Crypto to fiat user profile tab, the bridgeXYZMutation
crashes
So the KYC button doesn't show up:
I have all the env
vars properly set, and have ran npm run prepare
(I've also tried setting the apiKey
inside the bridgeXYZMutation
to the sandbox key, but still no change)
8de12e9
to
06906fe
Compare
03168c5
to
a6876a0
Compare
@rdig looks like the import path was off, the joys of vanilla JS development 😃 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rdig I wondered if it's because of the obviously fake email you used but even with the same details, it works fine on my end. I am also connected to the sandbox API with the same key. Screen.Recording.2024-08-06.at.23.25.32.movLet's catch up on this tomorrow |
Yeah, it's possible I'm doing something wrong with my setup. |
Hey @rdig just chiming in -- I've seen this happen to me when I came from a branch that had a different network hash. Just thought I'd double check if you've restarted your dev again on this branch? But knowing you, you probably already have! |
As I remember yes, I rand this fresh, but if there are any doubts I can test again just to make sure my findings are not faulty |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I've stuck with using a US address and a US bank account all seems to be working @jakubcolony ✨
I can prove that I updated it because the id
field of the bankAccount
object has been updated yet the liquidationAddress
remained the same 👌
…to check kyc handler
…ents completed action view
c36a424
to
297858f
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Re-tested this (live, with @jakubcolony), with proper US and EUR accounts and not it's working as expected.
Description
See issue #2793 for details.
This PR resolves a number of potential issues with liquidation addresses:
It also removes the
bridgeXYZQuery
lambda, as handling both queries and mutations in a single lambda allows for less code duplication and easier deployments.Note: In this PR I'm also testing the possibility of splitting amplify schema into multiple files in hope to make it more manageable, considering the existing schema is already nearly 4k lines long.
Testing
Restart your dev env - otherwise the separate schemas will not get picked up.
Issue 1:
npm run prepare
.On next refetch the
CheckKYCStatus
query should return a liquidation address.Issue 2:
In production, if you updated bank details to EUR account, new liquidation address should be created. In sandbox however we can't really test subpoint 2).
Issue 3
You can run the following query with your user address to confirm it returns the liquidation address:
Resolves #2793