6

So, I want to test my app locally, but something goes wrong. After installing virtualenv, activating it, installing requirements.txt and running collectstatic I try to run app with

heroku local web -f Procfile.windows

I get

[OKAY] Loaded ENV .env File as KEY=VALUE Format

And that's all. I wait for about 30 mins and then stop execution. Then I get

16:07:33 web.1   |  Unhandled exception in thread started by <function check_errors.<locals>.wrapper at 0x042BEF60>
16:07:33 web.1   |  Traceback (most recent call last):

Traceback is empty. This is all output. Sometimes, when I wait for about only 1-2 minutes no messages appear at all.

File Procfile.windows looks like:

web: python manage.py runserver 0.0.0.0:5000

What's wrong? Why this exception occurs?

5
  • Why are you stopping the server? What are you expecting to happen? Commented Aug 12, 2017 at 14:42
  • Can we see more code? Is it just a hello world application? Commented Aug 12, 2017 at 16:32
  • 1
    @DanielRoseman, because there's no point in waiting longer, as it should start within a few seconds. Commented Aug 13, 2017 at 11:46
  • 1
    @User, yes it is. Commented Aug 13, 2017 at 11:49
  • But still I don't understand what you are expecting to see on the console. Did you try actually accessing the local server? Does it work? Commented Aug 13, 2017 at 12:11

1 Answer 1

2

I'm also having the same issue; however, I noticed that the procfile command IS being run, but heroku is swallowing the console output. Which means if there is an error in the django code, the server silently does not start.

I can run manage.py runserver manually to see the console output, but that means having to configure the .env variables separately (which I'd rather not do, as I have multiple Heroku/Django apps locally).

However, for some reason, if I save any project file (even with no changes) while the server is running, the console output starts to appear as expected

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.