Repository navigation
Conversation
Researchers invite a teacher from Django admin (email + study + pieces and
activities per piece). The teacher is emailed that study's Qualtrics survey
link carrying an opaque per-study pid. Qualtrics reports consent server-to-
server (per-study shared secret), then redirects to /s/{slug}/onboard, which
sends a consented teacher without a password to allauth's set-password page.
Planned pieces/activities are assigned to courses the teacher creates.
Implements Lab-Lab-Lab/cloud-architecture-dev-ops#11.
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Implements Lab-Lab-Lab/cloud-architecture-dev-ops#11.
Researcher flow
pid./api/qualtrics/{slug}/consent, then redirects to/s/{slug}/onboard?pid=…. If consent is on record and the teacher has no password, they're sent to allauth's set-password page.What's in it
teleband.studiesapp with three models:Study: one row per study, with Qualtrics IDs, the env var name of its secret, consent version, and a JSONconfig.StudyParticipant: one row per person per study, keyed bypid. Named this way so it isn't confused with courses'Enrollment.PlannedPiece: the pieces and activities chosen for a teacher.consent,declined):X-Study-Secretis compared in constant time before the body is read; the env var can hold comma-separated values for rotationpidmust belong to that study/s/{slug}/join: eligibility (exclude_if_enrolled_in),max_enrollment, reuse of an unfinished sign-up, optional anonymous entry/s/{slug}/onboard: checks for about 15s, then shows a "Check again" button/s/{slug}/withdraw: logged-in participant withdrawsSTUDIES_APP_HOME_URL(env var): where enrolled users who already have a password are sent.Notes for reviewers
withdrawuses a Django login session; the frontend would need an API version.post-completecallbacks.Testing
teleband/studies/tests/pass.teleband/users/tests/test_admin.py::test_addandtest_drf_views.py::test_mefail, but they fail the same way onmain.🤖 Generated with Claude Code