Eva
Eva
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
14 replies
CCConvex Community
Created by gioru on 8/27/2024 in #support-community
Need help with handling Convex Auth signIn errors in prod
These two basic ones would cover most cases, I imagine: - Account doesn't exist / email not found - Login rate limit exceeded For the password reset flow (these may exist already?, haven't checked): - Code expired - Invalid code
30 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
I will give it a stab!
14 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
startsWith could be more forgiving than === but less than contains
14 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
I’m just imagining cases where there’s an extra space after the line, or an inline comment like .env.local # convex local env variables
14 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
And if so would a PR be welcome?
14 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
Would the check work using line.includes(“.env.local”) instead of line === “.env.local”?
14 replies
CCConvex Community
Created by Eva on 12/21/2024 in #support-community
`npx convex dev` always adds `.env.local` to `.gitignore`?
I’m on Mac, but the contributors may have been on Windows, I’m not sure.
14 replies
CCConvex Community
Created by gioru on 8/27/2024 in #support-community
Need help with handling Convex Auth signIn errors in prod
@Michal Srb do you know if there's a workaround for this right now? Or does it require a library change
30 replies
CCConvex Community
Created by gioru on 8/27/2024 in #support-community
Need help with handling Convex Auth signIn errors in prod
I see there's a callback for invalid password handling, but there isn't one for an invalid email, and the errors get stripped from the app in production. Wondering what the most straightforward way is to implement this common error state
30 replies
CCConvex Community
Created by gioru on 8/27/2024 in #support-community
Need help with handling Convex Auth signIn errors in prod
I'm trying to figure out how to display a simple "email does not exist" message for users who sign in with an invalid ID — I've read through this thread and a few issues on GitHub but it's still unclear. Am I correct in understanding that there's no way to display this message currently without creating a custom provider?
30 replies
CCConvex Community
Created by Eva on 12/9/2024 in #support-community
Testing `withIdentity` in `convex-test`
Ah, that worked! Thank you!
const userId = await t.run(async (ctx) => {
return await ctx.db.insert("users", {
email: "test@example.com",
role: "user",
});
});

const asUser = t.withIdentity({ subject: userId });

await asUser.mutation( ...an auth-required mutation )
const userId = await t.run(async (ctx) => {
return await ctx.db.insert("users", {
email: "test@example.com",
role: "user",
});
});

const asUser = t.withIdentity({ subject: userId });

await asUser.mutation( ...an auth-required mutation )
7 replies
CCConvex Community
Created by Eva on 12/9/2024 in #support-community
Testing `withIdentity` in `convex-test`
What is the subject field?
7 replies
CCConvex Community
Created by Eva on 12/9/2024 in #support-community
Testing `withIdentity` in `convex-test`
Put another way — is there a way to mock the ctx of a Convex function during testing?
7 replies
CCConvex Community
Created by Eva on 11/30/2024 in #support-community
React Testing Library + Vitest + Convex Test?
Ooh I hadn’t seen this article! Thanks @sshader!
16 replies
CCConvex Community
Created by Eva on 11/30/2024 in #support-community
React Testing Library + Vitest + Convex Test?
it may be worth just making a one static for your immediate purpose
What do you mean by this?
16 replies
CCConvex Community
Created by Eva on 11/30/2024 in #support-community
React Testing Library + Vitest + Convex Test?
You're right, I may be overcomplicating it! Should probably just try to avoid relying on backend logic when testing component display functionality.
16 replies
CCConvex Community
Created by Eva on 11/30/2024 in #support-community
React Testing Library + Vitest + Convex Test?
Specifically I’m interested in mocking query or mutation failures in order to write unit tests to display error messages.
16 replies
CCConvex Community
Created by Eva on 9/5/2024 in #support-community
Setting up a custom domain
28 replies
CCConvex Community
Created by Eva on 9/5/2024 in #support-community
Setting up a custom domain
I hope this helps!
28 replies