Search code examples
pythondjangowebgithubread-eval-print-loop

Django app working on my system but not working on repl.it


So I created Django app: https://github.com/Paresh-Wadhwani/toDo_Django

Then I imported the above repo to repl.it: https://repl.it/@pareshwadhwani/toDoDjango#README.md

It is working perfectly fine on my system but on repl.it it is just showing a blank page.

Here's what I did:

  1. Imported the codebase from Github into repl.it.
  2. Added the repl link to ALLOWED_HOSTS in settings.py.
  3. Executed the command "python manage.py migrate".
  4. Clicked Run [It executes the command "python manage.py runserver 0.0.0.0:3000"]

Now on repl, it is just showing this blank page.

ScreenShot

I am new to Django and to Web Development. Any help would be appreciated.


Solution

  • This question is from two months ago, so perhaps the OP was able to find the answer. But the question still needs to be answered. Inside repl.it, I've noticed that the window can appear to be blank or even showing errors such as this:

    DisallowedHost at /
    Invalid HTTP_HOST header
    

    and yet the app is actually running properly in the browser.

    So to try it out, I imported the OP's app from github into repl.it. Sure enough, it appeared not to be working, until I clicked the tiny icon in the upper right corner that shows a little box with an arrow. The result was that the app opened properly in my browser.

    enter image description here