Rank 1: Thread
same with commenting out some of the data
Votes
0
Replies
24
Participants
Unknown
Messages
25
Rank 1: Thread
same with commenting out some of the data
Moderator
I recommend trying to get only 1 response. Maybe that's causing a confilct
Moderator
Since the function is supposed to stop being executed when a response is returned
Rank 1: Thread
Right on - I removed the return statement and it's running right now
Rank 1: Thread
Yeah same error still and same logs
Moderator
You're triggering the function from SDK?
Admin
How long does it run for?
Rank 1: Thread
from the appwrite console
Rank 1: Thread
however long I set the timeout to
Admin
Maybe you're running into the timeout then
Moderator
Try setting it to like 2 minutes. I think that will be enough
Rank 1: Thread
I was wondering so I upped it to 5 minutes and same problem
Admin
Make sure to call return like return res.json().
Make sure you're only passing a single string to log()
Admin
Maybe it's really taking that long
Moderator
He's not calling it with JSON, but I think it should be fine anyways?
Admin
I see multiple arguments being passed to log
Moderator
Oh, yes, the latest line confused me 😅
Rank 1: Thread
Whoops about the logs, fixed those and added a return statement to the try block and timed out at 2 minutes - it's only like 2k documents with 10 attributes but I'll up it to 10 minutes and see what happens
Rank 1: Thread
@Steven @D5 appreciate the help guys - I make sure to bang my head on my keyboard at least a thousand times before asking for help but this 500 error was baffling me
Moderator
No issues, don't hesitate to ask anything at any time! We will always try to help 😄
Moderator
@conleyc86 This got solved from what I understand, true?
Rank 1: Thread
Yes! The function was too slow - indexing the ingested data and batching document creation/updating solved it - function runs in under a minute
Rank 1: Thread
Thanks again!
Rank 1: Thread
Also sorry for the slow reply - this is for a personal project just revisited it today.
Moderator
[SOLVED] "Error Msg: Http invalid protocol" After my function runs successfully.