How do you call a function from a sub file in python
I'm trying to query data from a function.
here is my python query
Attached a photo of my folder structure and get this error. Don't think my above code is right, or is this possible to do in python?
9 Replies
Yep the syntax is different @Hosna Qasmei, it's "plans/queries:getAll..."
Ah I was missing the / ðŸ˜
Thank you Tom!!
Live saver
we should add an error message helper that notices this and put an example in the docstring
Yeah I couldn’t find it anywhere for that case
Adding it here would be nice too https://pypi.org/project/convex/
now im getting a validation error 😅 , in typescript I just do an or something. do i need to do that with python too?
i don't think that user id is a valid
v.id("users")
, which would refer to the _id
field of the users
table and is generated by convex. what is the type of the userId
field on plans
?ah yes, didnt think to check their that was it. Had when it should just been that you now it's working