Runar Ovesen Hjerpbakk

Software Philosopher

Jekyll - ERROR bad Request-Line

Some of my regular readers might get déjà vu; this is the return of ERROR bad Request-Line.

The bug

As you can see in the screenshot below, I’d built my site successfully, but every request failed with the same error:

ERROR bad Request-Line

And then a bunch of gibberish.

The cause

I serve the production version of over HTTPS, but while testing locally, the site uses only regular HTTP.

The cause of the error was that I took a link from production, changed to localhost:4000, and tried to navigate to a local HTTPS-version of the website. Jekyll did not understand this strange request and subsequently threw these errors.

The solution

In the future, I’ll refer to this blogpost and afterward remember that I should’ve used HTTP instead of HTTPS locally 😂.