andgineer / docker-amazon-dash-button-hack

Amazon Dash Button hack in Docker for Synology
http://masterandrey.com/posts/en/amazon_dash_button/
11 stars 8 forks source link

Does not work if settings files have BOM #4

Closed andgineer closed 7 years ago

andgineer commented 7 years ago

Traceback (most recent call last): File "amazon_dash.py", line 72, in main() File "amazon_dash.py", line 66, in main settings = load_settings() File "amazon_dash.py", line 32, in load_settings return json.loads(settings_file.read()) File "/usr/lib/python3.5/json/init.py", line 315, in loads s, 0) json.decoder.JSONDecodeError: Unexpected UTF-8 BOM (decode using utf-8-sig): line 1 column 1 (char 0)

andgineer commented 7 years ago

https://github.com/masterandrey/docker-amazon-dash-button-hack/commit/07b2cf057839178942a15043fd8847f3108a1c59