-
-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
fix: migrate from decommissioned ipfs gateway to new one #11985
base: main
Are you sure you want to change the base?
Conversation
CLA Signature Action: All authors have signed the CLA. You may need to manually re-run the blocking PR check if it doesn't pass in a few minutes. |
Bitrise✅✅✅ Commit hash: e63a16f Note
|
|
||
export default function migrate(state: unknown) { | ||
if (!ensureValidState(state, 56)) { | ||
// Increment the migration number as appropriate |
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.
NIT: I think we do not need this comment
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 just copied it from previous migration, looks useful reminder and not doing any arm...
if (decommisionedIpfsGateway === preferencesController.ipfsGateway) { | ||
preferencesController.ipfsGateway = newDefaultIpfsGateway; | ||
} | ||
// Return the modified state |
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.
NIT: I think we can remove this comment
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.
Same as above
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.
LGTM just left some comments
Co-authored-by: tommasini <46944231+tommasini@users.noreply.github.com>
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #11985 +/- ##
==========================================
+ Coverage 55.12% 55.31% +0.18%
==========================================
Files 1750 1765 +15
Lines 39559 39756 +197
Branches 4922 4955 +33
==========================================
+ Hits 21807 21990 +183
- Misses 16249 16259 +10
- Partials 1503 1507 +4 ☔ View full report in Codecov by Sentry. |
Quality Gate passedIssues Measures |
Description
Note
this is only a state migration, the user will not have any visible warnings. It will only show the new gateway as selected instead of the decommissioned one if it was in their state.
Related issues
Fixes #11692
Manual testing steps
Screenshots/Recordings
Before
Simulator Screenshot - iPhone 16 Pro - 2024-10-23 at 22 00 21
After
Simulator Screenshot - iPhone 16 Pro - 2024-10-23 at 22 15 31
Pre-merge author checklist
Pre-merge reviewer checklist