Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deploy on Heroku: /backup gives 404 #348

Closed
throwaway34241 opened this issue Jan 3, 2022 · 8 comments · Fixed by #356
Closed

Deploy on Heroku: /backup gives 404 #348

throwaway34241 opened this issue Jan 3, 2022 · 8 comments · Fixed by #356
Labels
bug Something isn't working

Comments

@throwaway34241
Copy link

Describe the bug

I just freshly deployed to Heroku, but when I click on the top backup navigation item, it gives a 404.

heroku logs doesn't show anything meaningful, just a 404 line.

Version

Deployed 023951a to Heroku

To Reproduce

  1. Click on the purple Heroku button on the readme
  2. Wait for the deployment to finish
  3. Click on "Backup" in the web UI

Expected behavior

Backup works

Screenshots
Screenshot 2022-01-03 at 19 19 39

Desktop (please complete the following information):

  • Heroku free

Additional context
Add any other context about the problem here.

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 3, 2022

I can confirm this one, the callback looks totally fine /normal

@app.route("/backup", methods=['GET'])

Heroku logs tell me also

2022-01-03T18:54:13.810144+00:00 heroku[router]: at=info method=GET path="/backup" host=xxx.herokuapp.com request_id=b512d27b-5ad1-44e0-a236-bf82b339ed4d fwd="xxxx" dyno=web.1 connect=0ms service=10ms status=404 bytes=375 protocol=https
2022-01-03T18:54:13.810339+00:00 app[web.1]: xxxx,10.1.23.119 - - [03/Jan/2022 18:54:13] "GET /backup HTTP/1.1" 404 375 0.008075

I have no idea just yet!

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 3, 2022

Only thing I can think of is that there should be a test added, in the case that the build is missing something, so I've added that, and i can see in the test that the cleanup old backups step was sometimes broken for new sites, so maybe it was 404'ing when that happened (fixed that also)

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 3, 2022

so the test passes, so github pytest can confirm the /backup link works, but I also see the same issue @throwaway34241 can you try deploy b33105d ?

@dgtlmoon dgtlmoon added the bug Something isn't working label Jan 3, 2022
@throwaway34241
Copy link
Author

Just tried deploying e211ba8, still the same issue.

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 3, 2022

@throwaway34241 can you try enabling the password protection (goto settings) ? does that let you access it?

Yeah looks like the right commit https://github.com/dgtlmoon/changedetection.io/blob/e211ba806f123e24de053965b17617a88d1d5eb1/changedetectionio/tests/test_backup.py

@throwaway34241
Copy link
Author

I can add password protection, it works (asks for my password), but then still 404 on /backup

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 3, 2022

I'm tempted to start a branch where the URL is like /magical-monkey instead of /backup and see if there's something inside of Heroku interrupting this, the callback looks pretty much the same as the others

@dgtlmoon
Copy link
Owner

dgtlmoon commented Jan 5, 2022

@throwaway34241 yeah looks like it didnt like the non-relative path definition in the setup

  changedetection: python3 ./changedetection.py -C -d ./datastore -p $PORT

should be fixed now, i wasnt sure where the best place to put the datadir on heroku was

dzek69 pushed a commit to dzek69/changedetection.io-non-root that referenced this issue May 10, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants