Flask API not working in deployed version, but works in dev


I’ve been using this API for a while with no issues by simply waking it up on each request: https://replit.com/@trendoscope/Tradingview-Access-Management

So now that Replit has moved to deployments, this no longer works, all requests return 500, although in dev everything works smoothly. I went with Reserved VM as it is an API, but the issue persists with other deployment types too.

I found someone else struggling with the same API when deployed, conclusion being that this is due to Replit DB not supported for deployments: Issue with deployment of Flask API.

So in this API the DB is used to store session ID when logging into a website, but now it’s inaccessible (I wonder why?) for deployments. Due to this, there is no way to use this API currently and a workaround is needed. If anyone is struggling with a similar issue, any pointers are appreciated.


Upgrade replit package using shell and re-deploy your project. Works fine now.