-
-
Notifications
You must be signed in to change notification settings - Fork 124
Migrate vault entries to new schema #2092
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
base: master
Are you sure you want to change the base?
Conversation
5729ce6
to
b35f1f7
Compare
1423528
to
5f09dea
Compare
lib/object.js
Outdated
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 ended up only using get
to access properties via a nested path like a.b.c
(see tests).
I'll remove the other object helper functions if they don't turn out to be helpful in other places even though they have already been tested.
this isn't outdated, it just says so because I rebased the branch
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 didn't test the migration with Blink and Phoenixd, only made sure that it looks good so far.
I want to test them with wallets from production since attaching Blink or Phoenixd with only mainnet support is hard in regtest mode.
this isn't outdated, it just says so because I rebased the branch
nwcUrlSendId Int? @unique | ||
nwcUrlSend Vault? @relation(fields: [nwcUrlSendId], references: [id]) |
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.
Oh, instead of TODO_newName
in the wallet def, I could just use nwcUrl
instead of nwcUrlSend
. Then the new schema would match the existing typedef. Same for WalletBlink
.
@@ -16,7 +16,8 @@ export const fields = [ | |||
.matches(/^blink_[A-Za-z0-9]+$/, { message: 'must match pattern blink_A-Za-z0-9' }), | |||
help: `you can get an API key from [Blink Dashboard](${galoyBlinkDashboardUrl}).\nPlease make sure to select ONLY the 'Read' and 'Write' scopes when generating this API key.`, | |||
requiredWithout: 'apiKeyRecv', | |||
optional: 'for sending' | |||
optional: 'for sending', | |||
TODO_newName: 'apiKeySend' |
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.
Dear future @ekzyis, see other comment regarding TODO_newName
5f09dea
to
7dbdc2e
Compare
Description
This PR replaces the existing
VaultEntry
table which links to a row in the genericWallet
table (and to a row in theusers
table) with a new tableVault
where columns in the specific wallet tables likeWalletNWC
link to it.TODO:
upsertWalletXXX
mutationVault
tableVaultEntry
tablewallets
queryVault
table instead of from oldVaultEntry
tablemodels.vaultEntry
callsinjectResolvers
getVaultEntries
queryupdateVaultKey
mutationclearVault
mutationcheckWallet
jobTODO_newName
VaultEntry
tableScreenshots
Additional Context
tbd
Checklist
Are your changes backwards compatible? Please answer below:
tbd
On a scale of 1-10 how well and how have you QA'd this change and any features it might affect? Please answer below:
tbd
For frontend changes: Tested on mobile, light and dark mode? Please answer below:
n/a
Did you introduce any new environment variables? If so, call them out explicitly here:
no