feat(developer): manage the GitHub account from a developer rail - #948
Merged
Merged
Conversation
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 8409056317
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
vladjerca
force-pushed
the
feat/developer-profile-rail
branch
from
September 23, 2026 09:13
8409056 to
e1c5ca9
Compare
Connecting GitHub now happens once per account rather than on the create form, so it moves to a Developer panel beside the apps grid. - The rail shows the linked account, app usage against the limit, and re-verify, switch account and unlink. Unlinking asks for the GitHub handle to be typed, the same pattern as deleting an app. - An account with apps but no GitHub link sees them as normal and working, with the rail asking it to connect before creating more. - The create tile and /apps/new are only reachable with a linked account; /apps/new redirects to My Apps otherwise. - Switching accounts is chosen before the GitHub redirect, since a code works once, and is sent to the worker as switch: true. - The create form drops its Connect block and states which verified account the app is being created under. The API now answers with error codes rather than sentences, so account requests map each code to the portal's own copy. A refused link says why, and server text is still never shown.
vladjerca
force-pushed
the
feat/developer-profile-rail
branch
from
September 23, 2026 09:20
e1c5ca9 to
b4ae26b
Compare
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.
Why
Connecting GitHub now happens once per account rather than per app, so it no longer belongs on the create form. This moves it to a Developer panel beside the apps grid, the "profile rail" option from the design exploration.
What changes
DeveloperRail.svelte) beside the apps grid, in three states:/apps/newruns the same check and redirects to My Apps for an unlinked account or one at its limit, so the form is never reachable when creating would fail.stateand sent asswitch: true.Applications.svelte, which has the account slot the API call needs, soroutes/(portal)/apps/+page.sveltegoes back to rendering the page, like thenewroute.Error codes are localized on the client
The API now answers every developer and applications error with a stable snake_case code in
error, for examplegithub_account_taken, instead of an English sentence.developerErrorMessage.tsmaps each code to the portal's own copy, andaccountRequestuses it for every status. An unknown code, a non-string value or a plain-text body falls back to the existing per-status copy.That keeps the portal's rule that server output is never shown to the user: the portal only ever displays text it owns. The existing
does not echo error bodies or credentialsspec still passes unchanged, and a new one checks that a server sentence is not shown even inside a JSONerror.developerErrorMessage.spec.tslists every code the API can return and checks each has copy, so a code added on the API side without portal copy shows up as a missing entry there. The portal has no translation layer today, so the copy is English, but it now lives in one table ready for one.The generic 400 copy also changes from a GitHub-specific message to a neutral one, because most 400s here are about app details, not GitHub.
Depends on
The API change that adds
GET /v3/users/me/developerandPUTandDELETEon/v3/users/me/developer/github. It has to be live first: until then the rail cannot load and the create tile stays locked for everyone.Checks
deno fmt --check --config deno.jsonpassesdeno task format:svelte:checkpassesdeno task check: 369 files, 0 errors, 0 warningsdeno lintpassesdeno task test: 198 tests passed. New specs fordeveloperProfile.ts, the rewrittengithubConnect.ts, copy for every error code, and the error-message boundariesNot verified end to end
As with #945, the portal hardcodes
https://api.trakt.tv(#947), and the new endpoints are not deployed yet, so this cannot be exercised locally against a real API. It is covered by unit specs and should be smoke tested on production once the API change ships.