deislabs / bindle

Bindle: Object Storage for Collections
Apache License 2.0
263 stars 37 forks source link

Clearer error on bad token file #230

Closed itowlson closed 3 years ago

itowlson commented 3 years ago

Previously if you had a bad token file (like, one left over from a previous go at Bindle auth) it gave you

Invalid TOML

Error trace:
        1: expected an equals, found eof at line 1 column 41

which didn't help you resolve it.

With this change it gives you:

Invalid configuration: Error loading token file "/home/ivan/.config/bindle/.token": Invalid TOML

which is hopefully enough to track down the problem and decide what you want to do about it.

Fixes #228.