-
Notifications
You must be signed in to change notification settings - Fork 4.2k
fix: Unfinished migration on fail in one legacy library [FC-0107] #37521
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: Unfinished migration on fail in one legacy library [FC-0107] #37521
Conversation
|
Thanks for the pull request, @ChrisChV! This repository is currently maintained by Once you've gone through the following steps feel free to tag them in a comment and let them know that your changes are ready for engineering review. 🔘 Get product approvalIf you haven't already, check this list to see if your contribution needs to go through the product review process.
🔘 Provide contextTo help your reviewers and other members of the community understand the purpose and larger context of your changes, feel free to add as much of the following information to the PR description as you can:
🔘 Get a green buildIf one or more checks are failing, continue working on your changes until this is no longer the case and your build turns green. DetailsWhere can I find more information?If you'd like to get more details on all aspects of the review process for open source pull requests (OSPRs), check out the following resources: When can I expect my changes to be merged?Our goal is to get community contributions seen and reviewed as efficiently as possible. However, the amount of time that it takes to review and merge a PR can vary significantly based on factors such as:
💡 As a result it may take up to several weeks or months to complete a review and merge your PR. |
rpenido
left a 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.
LGTM 👍
Thank you for your work, @ChrisChV!
- I tested this using the instructions from openedx/frontend-app-authoring/pull/2555
- I read through the code
- I checked for accessibility issues
- Includes documentation
This is working as expected, but can't we just use the task_status field with UserTaskStatus.FAILED instead of creating a new is_failed field?
The I did the above to fix the error where items from other libraries were being created, but the migration was cut off when the error occurred with the library with a long key, and it didn't finish creating/organizing the data into collections. The other option was full migration regression, but using a transaction was something that was ruled out, and doing a manual regression would be very complex to do. |
bradenmacdonald
left a 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.
The UserTaskStatus represents the status of the entire bulk migration; a FAILED status means that the entire bulk migration has failed. Each ModulestoreMigration saves the data of the migration of each legacy library. I added is_failed to keep track a failed legacy library (like the large keys), but allow continuing with the migration of the rest of the libraries.
@ChrisChV Could you please include this information/explanation as a comment near the new is_failed field?
Conditional approval if you add an explanation into the code itself :)
- Adds the logic of partial migration: If the import of a library fails, then mark it as failed and continue with the next library
77bfd23 to
78ce65d
Compare
…enedx#37521) - Fix the issue described in openedx/frontend-app-authoring#2169 (comment) - Adds `is_failed` field to migrations. - Adds the logic of partial migration: If the import of a library fails, then mark it as failed and continue with the next library.
Description
is_failedfield to migrations.Supporting information
Testing instructions
Follow the testing instructions in openedx/frontend-app-authoring#2555
Deadline
ASAP
Other information
N/A