How to figure out what my PYTHONPATH environment variable should be

Nnova5/24/2023
I am getting a ModuleNotFoundError: No module named. I do not have this problem when running the applicaiton through Pycharm or through the terminal. I believe I have it in railway, because the sys.path on Railway is different from that on my own machine. How do I figure out the directory dtructure in a deployed railway application so I can modify the PYTHONPATH environment variable in Railway.
Nnova5/24/2023
e4949be4-03c7-44a7-a413-32ffc2e9c2f7
Bbrody5/24/2023
is the required module in your requirements.txt file?
Nnova5/24/2023
the required module is actually my own module, but in a different directory
Bbrody5/24/2023
then just use relative paths
Nnova5/24/2023
My Project/
├─ utils/
│ ├─ new_file3.py
│ ├─ new_file2.py
│ ├─ new_file.py
├─ Fast API/
│ ├─ main.py
Nnova5/24/2023
Imagien this is my directory structure
Nnova5/24/2023
I want to be able to import new_file into my main app
Nnova5/24/2023
it works on my machine if I add my project to sys.path
Nnova5/24/2023
but not on railway
Bbrody5/24/2023
definitely shouldn't be doing this, even locally
Bbrody5/24/2023
again, use relative paths
Nnova5/24/2023
is there any way to do it with absolute paths?
Bbrody5/24/2023
the word "relative" comes to mind
Nnova5/24/2023
@Brody
Bbrody5/24/2023
#🛂|readme #5
Nnova5/24/2023
my bad sorry
Nnova5/24/2023
btw for anyone looking at this in the future with the same error what I did instead was to set the project root as the outermost directory and use the following "start command"

uvicorn api.fast_api.main:app --reload --host 0.0.0.0 --port $PORT

I didn't know that you can run a uvicorn application similar to how you run a python module with the . syntax

This allowed me to continue to use absolute imports as I was getting errors with relative imports.