Skip to content

Hosted: pgstencil 0.4.1, and count logins and new accounts - #1403

Merged
nedtwigg merged 4 commits into
mainfrom
hosted-login-counts
Oct 28, 2026
Merged

nedtwigg merged 4 commits into
mainfrom
hosted-login-counts

Conversation

@nedtwigg

Copy link
Copy Markdown
Member

Bumps pgstencil and @pgstencil/auth to 0.4.1 (diffplug/pgstencil#80) and uses its new auth hooks to count account.created and login [email | provider id] in Hosted's daily metrics (#1398).

  • Best effort, as Hosted: aggregate daily launch counts, link refs, and an admin metrics page #1398's writes are: the hooks run after the write commits and are never awaited. waitUntil keeps them alive, and a failure is only logged, so a count can never fail or delay sign-in. They are wired into the production account Worker, the preview Worker, and the dev server.
  • Linking a provider counts no login. pgstencil does the exclusion, and the existing callback, replay and explicit-linking test covers it from our side.
  • What else changes:
    • /admin/metrics shows both new events.
    • hosted.md → "Metrics" and the Privacy page list them.
    • The policy date is already today, so it doesn't move.
  • The bump: 0.4.1 brings Better Auth 1.7.12 and drops @opentelemetry/semantic-conventions, and the dependency disclosure is regenerated. Hosted doesn't use @pgstencil/stripe yet, so its new migration doesn't apply here.

🤖 Generated with Claude Code

nedtwigg and others added 3 commits October 28, 2026 04:00
Brings Better Auth 1.7.12 and the auth login hooks. No new auth
migration; Hosted does not use @pgstencil/stripe.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
pgstencil's auth hooks write login [email | provider] and account.created
through the existing daily counts, best effort: a hook's write never
rejects, only logs, and pgstencil never awaits it or fires it for linking.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@cloudflare-workers-and-pages

cloudflare-workers-and-pages Bot commented Oct 28, 2026 •

Copy link
Copy Markdown

Deploying mouseterm with  Cloudflare Pages  Cloudflare Pages

Latest commit: 1c3bbf6
Status: ✅  Deploy successful!
Preview URL: https://6961fd34.mouseterm.pages.dev
Branch Preview URL: https://hosted-login-counts.mouseterm.pages.dev

View logs

…-conventions

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@nedtwigg
nedtwigg merged commit 099b8f3 into main Oct 28, 2026
18 checks passed
@nedtwigg
nedtwigg deleted the hosted-login-counts branch October 28, 2026 11:21
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants