Scoped field updates in custom Morango sync ops - #14985
Conversation
d49c62f to
598efb9
Compare
🔵 Review postedLast updated: 2026-07-09 00:22 UTC |
rtibblesbot
left a comment
There was a problem hiding this comment.
PR #14985 — Small, correct cleanup: a None guard on records_total in the sync progress hook plus scoping two morango save() calls to their changed fields. Both are consistent with this branch's earlier "scope saves to changed fields" work, and the test assertion was updated to match. CI pending; no UI changes (Phase 3 N/A).
One worthwhile follow-up (inline): the new guard doesn't cover the sibling stats handler in the same adapter, so the crash it targets can still fire. Minor: the guard has no test, unlike the update_fields change.
@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
Ran a phased review pipeline over the pull request diff:
- Classified the diff to select review passes (core, frontend, backend) and whether manual QA was required
- Core review pass checked correctness, design, architecture, testing, completeness, and DRY/SRP/Rule-of-Three principles
- Specialized frontend/backend review passes applied framework-specific lenses where those files changed
- For UI changes: manual QA and an accessibility audit against a live dev server, when available
- Checked CI status and linked issue acceptance criteria
- Synthesized one review from those passes and chose the verdict from the findings, CI status, and QA evidence
598efb9 to
6614d8e
Compare
Build Artifacts
Smoke test screenshot |
rtibbles
left a comment
There was a problem hiding this comment.
Changes make sense to me - one thought for the future, but not needed right now.
| extra_fields.update(**storage) | ||
| context.sync_session.extra_fields = json.dumps(extra_fields) | ||
| context.sync_session.save() | ||
| context.sync_session.save(update_fields=["extra_fields"]) |
There was a problem hiding this comment.
Not needed for now - but it almost feels like having "dirty field" tracking on the sync session might be good to have this be the default behaviour.
44bf426
into
learningequality:release-v0.19.x
Summary
References
Related to this investigation:
Also, this corresponding morango update:
Reviewer guidance
The guidance in learningequality/kolibri-sync-extras-plugin#15 is sufficient. Morango integ tests pass
AI usage
None