Skip to content

Password provider: setupUsernamePassword - #383

Merged
Nicolapps merged 2 commits into
rebootfrom
nicolas/auth-password-setup-function
Jul 10, 2026
Merged

Password provider: setupUsernamePassword#383
Nicolapps merged 2 commits into
rebootfrom
nicolas/auth-password-setup-function

Conversation

@Nicolapps

Copy link
Copy Markdown
Member

No description provided.

@vercel

vercel Bot commented Jul 8, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

1 Skipped Deployment
Project Deployment Actions Updated (UTC)
convex-auth-docs Ignored Ignored Jul 10, 2026 6:37pm

Request Review

@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from de07136 to db808a3 Compare July 8, 2026 22:52
@Nicolapps
Nicolapps changed the base branch from reboot to graphite-base/383 July 9, 2026 16:54
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from db808a3 to 1b0f630 Compare July 9, 2026 16:55
@Nicolapps
Nicolapps changed the base branch from graphite-base/383 to nicolas/auth-core-get-user-id-by-account July 9, 2026 16:55
* The provider function that completes an authentication flow should
* call this function when it has authenticated an account and return
* the result.
* It will be passed a {@link ProviderHelpers} bundle, provided by Convex

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Claude decided to change the parameters of the provider function in order to make it work. I don't feel great about it and I wonder if it would make more sense for providers to only receive a reference to the core component.

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mind the param change that much, and I like providing something more specific than the whole component for clarity.

Maybe we'll find that we're just repackaging the core component API and it makes sense to just collapse it back to that, but this seems fine for now.

@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch 2 times, most recently from 0427738 to e543b5f Compare July 9, 2026 17:25
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from e543b5f to eb69f5a Compare July 9, 2026 18:21
@Nicolapps
Nicolapps changed the base branch from nicolas/auth-core-get-user-id-by-account to graphite-base/383 July 9, 2026 18:25
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from eb69f5a to 6d8c361 Compare July 9, 2026 22:17
@Nicolapps
Nicolapps changed the base branch from graphite-base/383 to nicolas/auth-core-get-user-id-by-account July 9, 2026 22:17
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch 2 times, most recently from 1474d71 to dc12859 Compare July 9, 2026 22:53
// so this call should not fail.
// Throwing so that the transaction doesn’t commit.
//
// TODO(nicolas) can we improve this?

@Nicolapps Nicolapps Jul 9, 2026

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I kind of want to change setPassword to succeed or throw a Error, and ask from the caller that they run input validation first, to make sure we don't need to revert the user creation

@Nicolapps
Nicolapps changed the base branch from graphite-base/383 to nicolas/auth-core-get-user-id-by-account July 10, 2026 15:58
@Nicolapps
Nicolapps changed the base branch from nicolas/auth-core-get-user-id-by-account to graphite-base/383 July 10, 2026 16:00
Comment thread packages/core/src/lib/types.ts Outdated
Comment thread packages/core/src/lib/types.ts Outdated
* The provider function that completes an authentication flow should
* call this function when it has authenticated an account and return
* the result.
* It will be passed a {@link ProviderHelpers} bundle, provided by Convex

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't mind the param change that much, and I like providing something more specific than the whole component for clarity.

Maybe we'll find that we're just repackaging the core component API and it makes sense to just collapse it back to that, but this seems fine for now.

Copy link
Copy Markdown
Member Author

Thanks @dowski, I did another pass on docs in 2073301.

@Nicolapps
Nicolapps changed the base branch from graphite-base/383 to nicolas/auth-core-get-user-id-by-account July 10, 2026 17:44
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from 2073301 to 94dee2c Compare July 10, 2026 17:50
@Nicolapps
Nicolapps changed the base branch from nicolas/auth-core-get-user-id-by-account to graphite-base/383 July 10, 2026 18:16

Nicolapps commented Jul 10, 2026

Copy link
Copy Markdown
Member Author

Merge activity

  • Jul 10, 6:36 PM UTC: A user started a stack merge that includes this pull request via Graphite.
  • Jul 10, 6:38 PM UTC: Graphite rebased this pull request as part of a merge.
  • Jul 10, 6:40 PM UTC: @Nicolapps merged this pull request with Graphite.

@Nicolapps
Nicolapps changed the base branch from graphite-base/383 to reboot July 10, 2026 18:36
Nicolapps and others added 2 commits July 10, 2026 18:37
Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@Nicolapps
Nicolapps force-pushed the nicolas/auth-password-setup-function branch from 94dee2c to b29a8a6 Compare July 10, 2026 18:37
@Nicolapps
Nicolapps merged commit eca549e into reboot Jul 10, 2026
4 checks passed
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