Functions Failing Due to Installed Dependencies, Even Without Being Used
- 0
- React Native
- Functions

Hi team! Before anything, I am on the so far while we're in the planning phase of the app, and will be upgrading to pro soon. If there's a possibility that this is what's causing the issue below, please let me know.
I’m running into an issue deploying a Python function in Appwrite Functions. The function is intended to run an ML model called DeepSkin, which is used for wound segmentation and PWAT scoring for a healthcare client. This model requires the following dependencies:
numpy
mahotas
opencv-python
tensorflow>=2.8.0
gdown
git+https://github.com/Nico-Curti/Deepskin.git
The problem is not with my code, I’ve confirmed that everything runs fine without these dependencies. But once I include them (especially tensorflow, I suspect), I start encountering issues even when the function body just returns "hello world". In my build commands, I use pip install -r functions/requirements.txt
to install these dependencies.
Specifically: • The function builds fine, although it takes over 6 minutes each time I rebuild. • But on cold start, I get: Function timed out during cold start. Error Code: 400 • If I increase the timeout, I get: Synchronous function execution timed out. Use asynchronous execution instead, or ensure the execution duration doesn't exceed 30 seconds. Error Code: 408
Again, none of the heavy ML logic is being executed yet, just simply running the function with these dependencies being installed seems to be the issue.
Is there anything I can do? I really don't want to go back to using FastAPI, and these serverless functions were one of the main reasons I came to you guys. Any help would be appreciated!
Thanks!

Also it's really urgent so any help would be appreciated.
Recommended threads
- How to reduce cold start times for cloud...
Is there anything I can do to prevent slow responses? How long does it take for a function to enter a "cold state"?
- Auth Error
`const user = await createSessionClient(session).account.get(); ` node-appwrite package can work but react-native-appwrite package cannot work. The only diffe...
- Migration error 'Invalid Runtime: dart-3...
I try to migrate my project from a self hosted Appwrite 1.6.2 to another self hosted server (Appwrite 1.7.4). When it comes to migrate the functions i get the e...
