conradkoh
CCConvex Community
•Created by conradkoh on 11/21/2024 in #support-community
customQuery methods not findable from other package
I managed to solve this problem. Some of these strange issues were solved by ensuring that none of the convex packages were hoisted. aka - convex, convex-helpers, convex-test
I don't know the inner workings for why this should be the case, but this solved it for me. In yarn, the config looks like this
6 replies
CCConvex Community
•Created by conradkoh on 11/21/2024 in #support-community
customQuery methods not findable from other package
here's what I tried that doesn't seem to be working
- convex @ 1.17.x
- convex-helpers @ 0.1.65
I also tried to refer to convex-helpers and saw it was referencing 1.14.x and I tried downgrading - but doesn't seem to work.
6 replies
CCConvex Community
•Created by conradkoh on 11/21/2024 in #support-community
customQuery methods not findable from other package
@erquhart
Have you tried restarting the TS server in vs code since you updated convex?I have! first thing I usually do when there are type errors in the IDE 👍🏼
someone had a similar issue recently with tsconfig aliasyeah same! I actually moved away from aliases altogether in a convex project because it isn't the easiest to configure. actually any pro tips here on how to structure the project? I find the the convex folder has its own tsconfig, but unfortunately does not allow me to put all my code in there (e.g. for other util functions) so I end up having to put stuff in a src directory and have another tsconfig. am I doing something wrong?
I've seen folks have issues like this when aliasing the convex directoryalso in my case I am not aliasing the directory, but rather using workspaces (so the package name @workspace/backend is actually the package name. the rest gets resolved via module resolution. @ballingt
This can happen when multiple versions of convex-helpers or convex are being used, yeah suggest making sure these all match.mm I just tried updating convex-helpers and convex-test but doesn't seem to work..
6 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
yeah as far as I know, this is the first time!
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
yep! I do.
30 replies
CCConvex Community
•Created by Gary, el Pingüino Artefacto on 9/10/2024 in #support-community
How to aggregate documents (more than 16K)?
as for aggregation by different granularities, you could probably create something like a
doc_count
table.
you could have something like this
to control the complexity, you may want to just use the monthly to roll up into the year's ones, especially since it is just reading 12 records.21 replies
CCConvex Community
•Created by Gary, el Pingüino Artefacto on 9/10/2024 in #support-community
How to aggregate documents (more than 16K)?
another option is to maintain the counter on write rather than on reads. so keep a counter in a separate table and increment it when a new record is added. this is safe to do in convex because of optimistic locking I believe.
broadly
1. add the code to start incrementing the counter from a hard partition (e.g. if current time > 12pm on 11 Sep, then increment counter) => increment the col called
doc_count
2. wait for the time to pass until the deadline set in step 1
3. count all records that were created before the deadline => increment the col called doc_count_historical
once you are satisfied, with the historical count, you could just increment doc_count
by that number, and delete the doc_count_historical
col.21 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
haha okay it's down again 😂 maybe it's time to go outside I guess haha.
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
thanks dude
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
looks like it's back online.
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
oh wow, not that I've encountered. but from time to time things load really slow, so I generally don't use it much these days except for testing.
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
yes with warp!
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
do you have the same issue on your side?
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
30 replies
CCConvex Community
•Created by conradkoh on 9/10/2024 in #support-community
Is Convex websockets down?
I tried that too, at least via 1.1.1.1 - still the same issue.
30 replies
CCConvex Community
•Created by conradkoh on 8/13/2024 in #support-community
Errors when type inference for custom actions
ok nevermind, I found that specifying the return type of the
ctx.runQuery
function fixed it.2 replies
CCConvex Community
•Created by conradkoh on 7/13/2024 in #support-community
Slow deployments during dev
6 replies
CCConvex Community
•Created by conradkoh on 7/13/2024 in #support-community
Slow deployments during dev
and ok, I've just verified!
6 replies
CCConvex Community
•Created by conradkoh on 7/13/2024 in #support-community
Slow deployments during dev
6 replies