Consolidate two different implementations of serializing an XBlock to OLX#32115
Conversation
|
Thanks for the pull request, @bradenmacdonald! As a core committer in this repo, you can merge this once the pull request is approved per the core committer reviewer requirements and according to the agreement with your edX Champion. |
a5f38c1 to
e748c78
Compare
|
@Agrendalath This is ready for review. FYI @ormsbee - in case you want to review, up to you. |
e748c78 to
6d01fbc
Compare
Agrendalath
left a comment
There was a problem hiding this comment.
Nice cleanup!
👍
- I tested this: checked that the OLX content generated by the "Copy" functionality is identical (except for adding the
url_name) - I read through the code
- I checked for accessibility issues: n/a
- Includes documentation: n/a
- I made sure any change in configuration variables is reflected in the corresponding client's
configuration-securerepository: n/a
|
@bradenmacdonald 🎉 Your pull request was merged! Please take a moment to answer a two question survey so we can improve your experience in the future. |
|
EdX Release Notice: This PR has been deployed to the staging environment in preparation for a release to production. |
|
EdX Release Notice: This PR has been deployed to the production environment. |
1 similar comment
|
EdX Release Notice: This PR has been deployed to the production environment. |
Description
Ticket: openedx/modular-learning#54
This is just a refactor to make some code that I've been working on more DRY. i.e. it's removing some minor technical debt by consolidating two very similar classes that are used to serialize individual XBlocks to OLX - one that uses "normal" OLX and one that uses a blockstore-specific variant.
Or at least, that was the plan - I actually found some minor inconsistencies in the API when adding more tests for the new combined API, so it does include some bugfixes too. Mainly, it now always includes
url_namein the exported OLX except when in "blockstore mode"; before this it was inconsistent.Supporting information
See #31904 which introduced the duplication. I split this fix out into a separate PR so that the refactor can be evaluated on its own.
Testing instructions
Check that the test cases provide coverage and the copy-paste feature is still working.
Deadline
None
Other information
Private ref. MNG-3636