andrewshilliday / garage-door-controller

Software to monitor and control garage doors via a raspberry pi
MIT License
327 stars 132 forks source link

No json object could be decoded error #95

Closed commputethis closed 5 years ago

commputethis commented 5 years ago

I did a fresh install of Raspbian and followed your directions, but the website didn’t come up after setting it to start automatically and rebooting. So I ran “python controller.py” from the garage-door-controller directory and get a “no json object could be decoded” error. I tried redoing everything and tested prior to modifying the config file and still got the error. I wanted to make sure my edits hadn’t broken anything. Thoughts?

acd14b61-5350-479d-b270-c949ed3c159c

commputethis commented 5 years ago

If I take an older version of the config.json file and use it, then the site starts up fine, but the current one I get that error.

commputethis commented 5 years ago

I found the issue. Using the Files Compare Tool and comparing the old file to the new file I found there are 3 characters at the beginning of the file that were causing a problem: 

Removing the characters resolved the issue. I couldn't see those on the pi itself or in NotePad++.

image

andrewshilliday commented 5 years ago

Glad you got it working.