oTree Forum >

FileNotFoundError when directly deploying with Heroku

#1 by manond

Dear all,

I have deployed my experiment on Heroku thanks to GIT. But when running it on the server, some of my static files are not found (whereas others are). Yet, I can run it perfectly with my local server 'otree devserver' and no bug appears when running 'git push heroku master' in GIT (cf. attached screenshot). I am coding with oTree 5 and thus cannot use WhiteNoise module or any Django function. I already tried moving my files from a specific folder in static to the main static, also deleting and downloading them again.

Does someone have the same issue or know how to solve it ? I checked everywhere but cannot find a proper solution, except using S3 or Protges (which I prefer to avoid).

Many many thanks!

#2 by ChristianK

Hi manond,

Can you share the code you use to include one of the static files that does not show up?
Are you sure that the files in question have been added to the commit? (did you use git add . in the project root?)


#3 by manond

Hey ChristianK,

Thank you for your reply. I figured it out, it appeared that heroku was not calling the right otree file. I changed the directory and everything works properly now.


Write a reply

Set forum username