thermograph/frontend/static
Emi Griffith 81135c1be5
All checks were successful
secrets-guard / encrypted (pull_request) Successful in 6s
PR build (required check) / changes (pull_request) Successful in 11s
shell-lint / shellcheck (pull_request) Successful in 8s
PR build (required check) / validate-observability (pull_request) Has been skipped
PR build (required check) / build-frontend (pull_request) Successful in 57s
PR build (required check) / build-backend (pull_request) Successful in 1m25s
PR build (required check) / gate (pull_request) Successful in 1s
accounts: sign in with Google, on a shared provider-agnostic OAuth engine
Adds Google as a second identity provider. Rather than a second copy of the
Discord flow, the flow itself moves to accounts/oauth.py and both providers
become configurations of it — account resolution is the security-critical
part, and a parallel hand-rolled copy is where a subtle divergence becomes a
takeover. A third provider is now a PROVIDERS entry and nothing else.

Identity moves to an oauth_account table keyed (provider, subject), so a
login resolves on the provider's own stable id rather than an email that can
be changed or reassigned. user.discord_id deliberately stays: it is the DM
delivery address notify.py reads, not merely an identity, and the Discord
link keeps writing it. discord_only becomes oauth_only, and the lockout guard
now refuses to unlink the *last* provider from a password-less account rather
than singling out Discord — with two linked, either may go.

Migration 0005 renames the flag and backfills an oauth_account row for every
existing discord_id. Without that backfill an already-linked user would stop
being recognised at login and would silently get a second account on their
next sign-in. It also drops a vestigial discord_only that 0003 re-adds on a
database whose 0001 already built oauth_only from current metadata, which
otherwise left fresh and upgraded databases with different schemas.

Compatibility, since the frontend deploys independently of this service:
/discord/link/callback keeps answering because that URL is registered in
Discord's developer portal, the other /discord/* routes stay because the
deployed frontend calls them, the callback still emits ?discord= alongside
?oauth=, and UserRead still carries discord_only as a computed alias.

Google needs THERMOGRAPH_GOOGLE_CLIENT_ID/_CLIENT_SECRET and its own
registered redirect URI; unset, it reports disabled and shows no UI.
2026-07-26 17:53:34 -07:00
..
.well-known Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
account.js accounts: sign in with Google, on a shared provider-agnostic OAuth engine 2026-07-26 17:53:34 -07:00
app.js fix(frontend): Weekly view must always send an explicit date to /grade 2026-07-26 06:20:19 +00:00
apple-touch-icon.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
bookmarks-ui.js bookmarks: don't fabricate a local save when the server rejects it (#121) 2026-07-26 18:51:02 +00:00
bookmarks.js bookmarks: don't fabricate a local save when the server rejects it (#121) 2026-07-26 18:51:02 +00:00
cache.js fix(frontend): Weekly view must always send an explicit date to /grade 2026-07-26 06:20:19 +00:00
calendar.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
calendar.js Frontend QA batch: date/TZ, https origin, date-422, VAPID rotation, trace-precip, partial-day gate (#70) 2026-07-24 23:13:36 +00:00
chart.js Frontend QA batch: date/TZ, https origin, date-422, VAPID rotation, trace-precip, partial-day gate (#70) 2026-07-24 23:13:36 +00:00
climate.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
compare.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
compare.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
day.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
day.js Frontend QA batch: date/TZ, https origin, date-422, VAPID rotation, trace-precip, partial-day gate (#70) 2026-07-24 23:13:36 +00:00
digest.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
favicon-16.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
favicon-32.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
favicon-48.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
favicon.svg Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
filtersheet.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
google03ab95daa090e8d9.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
ios-install.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
legend.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
logo-192.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
logo-maskable-192.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
logo-maskable-512.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
logo.png Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
manifest.webmanifest Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
mappicker.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
nav.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
package.json Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
push-client.js Frontend QA batch: date/TZ, https origin, date-422, VAPID rotation, trace-precip, partial-day gate (#70) 2026-07-24 23:13:36 +00:00
score.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
score.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
shared.js Frontend QA batch: date/TZ, https origin, date-422, VAPID rotation, trace-precip, partial-day gate (#70) 2026-07-24 23:13:36 +00:00
style.css accounts: sign in with Google, on a shared provider-agnostic OAuth engine 2026-07-26 17:53:34 -07:00
subscriptions.html Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
subscriptions.js bookmarks: map + account UI for saved locations 2026-07-26 18:36:39 +00:00
sw.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00
units.js Subtree-merge thermograph-frontend (origin/main) into frontend/ 2026-07-22 22:01:11 -07:00