Move user_auth onto the new resource methods - #15207
Conversation
Build Artifacts
Smoke test screenshot |
b684450 to
e19868c
Compare
|
Three red checks, one cause. Both Transient PyPI/piwheels truncation rather than anything on this branch:
No code change to push, and re-running the job needs admin rights this account lacks. @rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly |
AlexVelezLl
left a comment
There was a problem hiding this comment.
Just a little request, please also rebase against develop again.
There was a problem hiding this comment.
Given that code is split into setup code and options API code, the useList usage has make this a bit harder to follow. Could you please revert the usage of useList here?
There was a problem hiding this comment.
Reverted — created() and setSuggestions() are back in the Options API, with fetchCollection({ getParams }) swapped for list(params). Net diff on this file is now those two calls.
Swept the branch for the same pattern: git grep -n "useList\|useFetch" kolibri/plugins/user_auth/ — those two were the only composable-in-setup() conversions; the other three call sites (SignUpPage, DeviceUnusableMessage) were plain method renames.
Kept the spec on the kolibri/client mock rather than the resource module: it is what proves facility still leaves as a query param instead of a getParams blob.
Rebased onto develop (479b7962c5).
|
Also, @rtibblesbot, please add |
16fbf82 to
b4f99f2
Compare
|
Added Swept the branch's five call sites for flows the section misses: Also force-pushed a history fix: the last self-review cycle left |
`create` resolves the server's response body where `saveModel` resolved it merged over the POST payload; the sign-up `.then` reads `picture_password`, which is read-only on `FacilityUserSerializer` and so only ever in the response. `clearAll_v2` resolves `response.data` rather than the whole axios response; the deprovision call site awaits and discards it. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
The spec moves its mock from the resource module to `kolibri/client`: the boundary is what proves `facility` still goes out as a query param rather than a `getParams` blob, which `list` would send as an unfiltered request. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
b4f99f2 to
753528b
Compare
AlexVelezLl
left a comment
There was a problem hiding this comment.
Thanks @rtibblesbot! Code changes look good, manual QA steps are clear and correct, ready for qa review :)
|
Holding off on changes while this PR is in Change the board status when QA is done and I'll pick up any outstanding review feedback, CI failures and conflicts on the next cycle. @rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly How was this generated?
|
Summary
facilityusernamereads inSignInPagemove tolist.create, so the payload is no longer nested underdata.TaskResource.clearAll_v2.References
Fixes #15067. Recipe: #15057. New methods: #15056.
Reviewer guidance
Code review
Collectioncache was module-level.createresolves the response body, not the body merged over the payload. The sign-up.thenreadspicture_password, which is response-only.SignInPage.spec.jsmockskolibri/clientrather than the resource: only the boundary provesfacilitystill leaves as a query param, not agetParamsblob.QA steps
No UI changes — sign-in and sign-up should behave as on develop. Rig: a facility with password-free sign-in and account creation enabled (Facility > Settings), 16 users or fewer, three sharing a prefix (
alice,alina,alvaro); a second facility with more; the APK for step 2.alion the small facility's sign-in page: the three usernames drop down. Select by mouse, then by arrow keys — both sign in. Backspacing toalempties it, Escape hides it.Unverified: the deprovision clear tasks path renders only on a device with no usable superuser.
search=alimax_results=16AI usage
Claude Code applied the recipe and wrote the tests. Verified with the
user_authJest suite, prek, and the QA above.@rtibblesbot's comments are generated by an LLM, and should be evaluated accordingly
How was this generated?
Deviations from the issue spec
useRetrieve/useListwhere possibleSignInPagemixessetup()with Options API; per review,useListthere splits state across both halves. Both reads uselist()instead.🟡 Waiting for feedback
Last updated: 2026-08-24 16:09 UTC