Repository navigation
feat(users): provision accounts through listed SSO providers with signup closed (#874) - #913
Merged
Merged
Conversation
…ettings settings.py was at the 300-line cap. UsersSettings inherits OAuthSettings, so every field stays on app.state.users.settings. Claude-Session: https://claude.ai/code/session_01M9neheZZEe3sVpDi2S3zT4
…osed (#874) A provider in oauth_signup_providers may create an account on first sign-in when it proved the email, whatever allow_signup says; the account gets oauth_signup_default_role (none when blank). Other providers keep following allow_signup, and local registration is unchanged. Claude-Session: https://claude.ai/code/session_01M9neheZZEe3sVpDi2S3zT4
Keep the settings editor's field order (OAuth fields last), restore UserManager.allow_signup, normalise provider names, tie OAUTH_PROVIDER_NAMES to build_clients by test, and document the provisioning role. Claude-Session: https://claude.ai/code/session_01M9neheZZEe3sVpDi2S3zT4
README states the provisioning role applies with signup open too. Claude-Session: https://claude.ai/code/session_01M9neheZZEe3sVpDi2S3zT4
Deploying simple-module-python with
|
| Latest commit: |
c68f0c8
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://cafe7716.simple-module-python.pages.dev |
| Branch Preview URL: | https://feat-issue-874-oauth-provisi.simple-module-python.pages.dev |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
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.
Summary
oauth_signup_providers(any ofgoogle,github,microsoft,oidc, normalised) andoauth_signup_default_role(blank means no role;adminis refused).allow_signupsays. An unproven email is refused, even with signup open. Listing a provider never loosens anything.oauth_signup_default_role, never the self-signupuserrole. Unlisted providers keep the old rule: they create accounts only withallow_signupon, and those accounts getuser. Local registration (the API, the/users/registerpage and the links) still followsallow_signupalone.users/core/oauth_settings.py(OAuthSettings), becausesettings.pywas at the 300-line cap.UsersSettings(OAuthSettings, _UsersCoreSettings)keeps the settings editor's field order, and a test checks it.UserManager.allow_signupstays for downstream readers.docs/modules/users.md(new "Provisioning accounts through SSO" section) and the CHANGELOG.docs/superpowers/specs/2026-11-11-oauth-provisioning-design.md.Closes #874
Verification
tests/core/settings/);tests/oauth/flow/test_users_oauth_provider_signup.py);tests/accounts/manager/test_users_default_role.py).make lintpasses, andmake test-jshas 906 passed.make test-pyhad 8363 passed and 1 failure:test_background_tasks_outbox_thread_loops, a wall-clock bound in an untouched module (1.77 s vs 1.5 s at load 13.5). It passes on its own (4/4).tyreturn-type errors after the split, which are fixed.Test plan
https://claude.ai/code/session_01M9neheZZEe3sVpDi2S3zT4