Saturday, August 29, 2020

Re: 500 Server Error | Impossible to Fix

Thank you for the feedback!

Intriguing, above the 500 error I see the following line: 

> Cart: {} 

In fact, I have a line in one of my HTML files that says Cart: {} under the JavaScript sector. Maybe this is the bug that needs to be fixed? 

The cart error plus the Heroku error are quite troublesome. I believe that the Heroku error may be able to be resolved via adding the full web address to ALLOWED_HOSTS in "settings.py". Time for a few test runs.

On Sat, Aug 29, 2020 at 11:42 AM Kunal Solanke <kunalsolanke1000@gmail.com> wrote:
500 is actually a internal server error ,it can easily resolved by just looking at the logger ,it dosen't only mean syntax error and definately not syntax errors of html file .Html file syntax errors are simply ignored I think you meant jinja code.Basic way to go around these is simply check the logger of your server ,see it will mention file and line where your code breaks and if its mentionaling terms like template loader and etc then your jinja code is wrong .



These error mostly occur at deploy or at time of fetching .


1.Deploy 
  Mostly problem with config vars

2.Fetching 
  Code is breaking somewhere.

On Sat, Aug 29, 2020, 20:55 King Niko <thelegendofearthreturns@gmail.com> wrote:
I managed to resolve the favicon 400 error. However, there still resides the Heroku error:

> at=info method=GET path="/" host=samplesite.herokuapp.com request_id= "private" fwd="private" dyno=web.1 connect=1ms service=99ms status=500 bytes=477 protocol=https

Any suggestions? Thank you!

On Sat, Aug 29, 2020 at 10:54 AM King Niko <thelegendofearthreturns@gmail.com> wrote:
Thank you so much for the help. The:

> heroku logs --tail

Definitely shows all of the errors. Two common errors that I have witnessed is:

> "GET / HTTP/1.1" 500 145 "https://dashboard.heroku.com/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko)"

>"GET /favicon.ico HTTP/1.1" 404 179 "https://samplesite.herokuapp.com/" "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko)"

These are both external errors. The first is a 500 error from Heroku and the second is a 400 error from Favicon. Any idea on how to resolve this issue?

Thank you again!

On Fri, Aug 28, 2020 at 9:59 PM RANGA BHARATH JINKA <bharathjinka09@gmail.com> wrote:
Hi,

    In settings turn the debug to True. Then check the error in terminal.

In heroku you have to check the logs in the terminal using heroku logs --tail

All the best 👍

On Sat, 29 Aug 2020, 4:35 am Lightning Bit, <thelegendofearthreturns@gmail.com> wrote:
Greetings all, 

I finally finished developing a Django website. 

In the terminal I checked: 

> python manage.py check --deploy

There were no errors and the program was ready for deployment. I even ran a:

> python manage.py runserver

There were also no errors on this end. Upon successfully porting the website to Heroku, I unfortunately got a 500 Server Error and then after editing, a 400 Server Error. I resolved the 400 Server Error by returning to the terminal and doing the following:

>python manage.py collectstatic

This resolved the 400 Server Error after pushing the data to the Heroku Master. Sadly, the 500 Server Error remained. I did a bit more research and discovered that 500 Server Errors usually arise from a syntax error in an HTML file or external file. I sifted for hours and did not find a syntax error. 

Could there be an alternative fix to the 500 Server Error that appears on the website? Does anyone know how to fix this? At this point, I feel as though I spent months developing this website for nothing. 

Please help if possible. Thank you! 

- Lightning Bit

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/cbe73ae9-c7c7-41de-95d5-1fab09ffdc17n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAK5m315%3DfBPaX57c%2BMMf8%2BDUmh9oVNXeN%3DuK_P6gAnLqeJDT9w%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAO1EWpGQgHS3vurP0UKn9xnG%3Dh-ea7hjkwWRWaD8%3D%3DW-AEa8jQ%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAOecAnyR%3D%3DtRa3sndcCFEsd6WJNwyt3bfcEGcY4OuaHx%3D-3UuQ%40mail.gmail.com.

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/CAO1EWpEpeKZv1M5Fdy20D6uvWsiR1drx_4nCc0Hypf05_45vLQ%40mail.gmail.com.

No comments:

Post a Comment