Chad Maycumber
CCConvex Community
•Created by Kevin on 8/29/2024 in #support-community
[Convex Auth] Middleware on Nextjs
Is it possible to get the current user on the NextJS middleware to check for a role for example?
11 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
Hmm that's true. Not the biggest deal I can create the embedding slightly later and update
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
Okay cool I figured. I reread the "zen of convex" and noticed I wasn't technically following the paradigm correctly
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
It does currently
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
Ahh that would make sense
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
Here's the bulk of the start of the action w/ the 2 mutations! I read recently I shouldn't be calling actions from the frontend whenever possible so I may need to re-factor things a bit!
17 replies
CCConvex Community
•Created by Chad Maycumber on 11/2/2023 in #support-community
Help with an edge case
Hey just saw this now! It does have two mutations!
17 replies
CCConvex Community
•Created by Chad Maycumber on 7/10/2023 in #support-community
Shared environment variables
I guess in my case I have multiple backends that share .env variables. I was thinking from convex to the locally running service so that convex could be used as the .env management solution to the other backends
13 replies
CCConvex Community
•Created by Chad Maycumber on 7/10/2023 in #support-community
Shared environment variables
@ballingt Oh sorry. That would be helpful context.
It executes the command with the environments variables in the current working directory from your .env, .env.local, etc.
The additional
--
just acts as a pass through so that you can still pass additional commands to whatever follows.
Here's how I'm currently using it with my dev command:
"dev": "dotenv -- turbo run dev",
.
Going back to earlier I think it'd be cool if I could do something like:
"dev": "convex env "turbo run dev"",
. Then I don't even need to worry about an env file13 replies
CCConvex Community
•Created by Chad Maycumber on 7/10/2023 in #support-community
Shared environment variables
I know there was talk about this on the way! Just dropping this here as I thought it could be interesting.
It would be nice if the convex CLI supported a command that mimicked
dotenv --
so that environment variables could be totally managed inside of convex13 replies
CCConvex Community
•Created by Chad Maycumber on 8/9/2023 in #support-community
What's the max payload side for an action, mutation, etc.
if you have very large content then generally the approach would be to split these into separate documents in the database or to store these as files if you don't need to treat them as metadataThis was exactly what I was thinking. Do you have a recommended approach here? Especially for something that might be updated periodically? I guess my question from a bandwidth perspective if I'm doing a lot of updates on largish files maybe that could get expensive?
8 replies
CCConvex Community
•Created by Chad Maycumber on 8/6/2023 in #support-community
Break schema into multiple files
Nice looking forward to seeing that I just made the move myself
6 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
Gotcha same for queries?
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
Yeah so what's happening for me is the I have a middleware that checks if the users authed and it throws an error if they hit a route that requires authentication. Because convex throws an error on the frontend they hit my error boundary
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
On this note. Is there something right now where I can maybe catch and check the convex error that get's thrown? Maybe I can try to check for a message in my error boundary
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
@ballingt You're right about the token length. I will go ahead and try to bump that as well
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
@clerk/nextjs@npm:4.21.10. convex@npm:0.19.1.
@Michal Srb Yeah I am. Clerk session token is also set to 1 year for me, but I guess that's probably different than the auth token length?
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/23/2023 in #support-community
"Failed to authenticate: \"Token expired\", check your server auth config" using Clerk
It's definitely when the users tab is sitting for awhile. Let me check. Maybe I need a better way to gracefully handle this
15 replies
CCConvex Community
•Created by Chad Maycumber on 7/19/2023 in #support-community
Running convex run in a CI environment
Cool that would be awesome
13 replies