Forums

Stuck at loading the website

Hello, I have developed code using flask and a remote mysql database. The code works perfectly on my local host but on pythonanywhere, the page is stuck at loading and it never loads. For the mysql database I use ssh tunnel to connect. I am not sure exactly what is the problem because the code works on my local computer.

the database that I am using is the one from pythonanywhere do I need to ssh tunnel in the first place? or can I just connect to my local mysql database and it should work

If the database you're using is the MySQL one that you set up on the "Databases" page inside PythonAnywhere, and your code is running inside PythonAnywhere, then you don't need to use an SSH tunnel -- those are only required if you're trying to connect from code that is running outside PythonAnywhere -- for example, from your own machine.