Skip to content

Update IndexedDB mutations#3687

Merged
bjester merged 5 commits intolearningequality:hotfixesfrom
rtibbles:mutations
Sep 29, 2022
Merged

Update IndexedDB mutations#3687
bjester merged 5 commits intolearningequality:hotfixesfrom
rtibbles:mutations

Conversation

@rtibbles
Copy link
Copy Markdown
Member

Summary

Description of the change(s) you made

  • Coerces channel_id returned from the API to be a hex string rather than - separated uuid for easier cross reference
  • Removes a duplicated (and possibly unreported error producing during change squashes) version of applyMods and uses the version from applyRemoteChanges
  • Updates all indexedDB update applying mutations to set the entire vuex map to ensure that new keys get set
  • Updates the assessment item mutation to handle the compound contentnode,assessment_id id key
  • Updates the file mutation to ensure that deletions applied in the indexedDB applyMods propagate to the other relevant maps
  • In so doing makes the fileUploadsMap the single source of truth, that then just copy to the other maps

Manual verification steps performed

Primarily tested this to ensure publishing was working as intended.

Screencast.from.09-27-2022.04.21.11.PM.webm.mp4

Automated test coverage for the file vuex module give me confidence about those changes.

Are there any risky areas that deserve extra testing?

Once this is merged, we should probably do another quick pass to ensure that all collaborative edits are showing up as intended.

References

Fixes #3683

Copy link
Copy Markdown
Member

@bjester bjester left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

setTasks(tasks) {
for (let task of tasks) {
// Coerce channel_id to be a simple hex string
task.channel_id = task.channel_id.replace('-', '');
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could probably remove the - replacement here with this change

@bjester bjester merged commit 99a75c8 into learningequality:hotfixes Sep 29, 2022
@rtibbles rtibbles deleted the mutations branch September 30, 2022 14:12
@bjester bjester mentioned this pull request Oct 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants