My first web app made in flask can't be deployed

1.  [imageobjectremover.streamlit.app](https://imageobjectremover.streamlit.app/)
2. https://github.com/bhavesh1oo/image_object_remover/  
3. ValueError: This app has encountered an error. The original error message is redacted to prevent data leaks. Full error details have been recorded in the logs (if you're on Streamlit Cloud, click on 'Manage app' in the lower right of your app).
Traceback:
File "/home/adminuser/venv/lib/python3.9/site-packages/streamlit/runtime/scriptrunner/script_runner.py", line 534, in _run_script
    exec(code, module.__dict__)
File "/mount/src/image_object_remover/main.py", line 125, in <module>
    app.run(debug=True)
File "/home/adminuser/venv/lib/python3.9/site-packages/flask/app.py", line 612, in run
    run_simple(t.cast(str, host), port, self, **options)
File "/home/adminuser/venv/lib/python3.9/site-packages/werkzeug/serving.py", line 1099, in run_simple
    run_with_reloader(
File "/home/adminuser/venv/lib/python3.9/site-packages/werkzeug/_reloader.py", line 439, in run_with_reloader
    signal.signal(signal.SIGTERM, lambda *args: sys.exit(0))
File "/usr/local/lib/python3.9/signal.py", line 56, in signal
    handler = _signal.signal(_enum_to_int(signalnum), _enum_to_int(handler))
  1. python version - 3.11.3
    my code is working fine in my system please help

As i already wrote in your previous thread, afaik you cannot run flask on the streamlit cloud infrastructure.

okay so can you tell me any other way to run this code on this cloud

You cannot host anything but streamlit apps on community cloud, so your choices are:

  1. Learn streamlit and rewrite your code from scratch as a streamlit app
  2. Host it somewhere else – my first google search pointed me to this, which seems like a good guide Deploying to Production — Flask Documentation (2.3.x)

This topic was automatically closed 2 days after the last reply. New replies are no longer allowed.