Getting error when app is deployed: CalledProcessError: Command '['python', PosixPath('./')]' returned non-zero exit status 120

Hello everyone, hope you all are doing great, I’ve been struggling several weeks to solve this error:

Traceback (most recent call last): File “/mount/src/cmwapp/pages/6_🧱”, line 16, in[“python”, “./scripts/”], check=True) File “/usr/local/lib/python3.11/”, line 571, in run raise CalledProcessError(retcode, process.args, subprocess.CalledProcessError: Command ‘[‘python’, ‘./scripts/’]’ returned non-zero exit status 120.

However this is only happening when the application is deployed (working fine locally), I checked several times the requirements.txt and changed pandas versions but it didn’t work. Does anyone know what can be the cause of this issue?

This is my repo: GitHub - ArielNi97/CMWapp: Confined Masonry Wall Application

The error seems to appear when running line 16 in the image below.

I appreciate any help, suggestions, recommendations that you may have, thank you in advance!

I assume the paths are not valid when running on streamlit cloud.
On streamlit cloud, all paths must be relative to the root folder of the github repo.
Therefore i would remove all the path manipulations and joins and use only relative paths.

Hi @Franky1, thanks for your input, I’ve tried what you suggested, also adding the “./” before the folder’s name that contains and that didn’t work, I also tried it without the “./” and leave only the “scripts/BuildMLInputFile,py”. Do you have any other idea to solve this? :frowning:

New update, I managed running well the app by changing the module and importing directly the other python files to the main script instead. I had to convert the called scripts to functions and import them to the main python script. I appreciate your help @Franky1 !

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