cesium-ml / baselayer

Fully customizable (scientific, compute-intensive) web application template
http://cesium-ml.org/baselayer/
30 stars 18 forks source link

Handle case where no Authorization header is provided #254

Closed acrellin closed 2 years ago

pep8speaks commented 2 years ago

Hello @acrellin! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 40:80: E501 line too long (88 > 79 characters)

Comment last updated at 2021-09-14 17:57:42 UTC
acrellin commented 2 years ago

@stefanv updated (though not sure what you're suggesting with the latter comment)

stefanv commented 2 years ago

I just meant that we are doing a generic catch, instead of checking the form of the header explicitly.

acrellin commented 2 years ago

Ah, don't lines 22-23 do just that?

stefanv commented 2 years ago

Hrm, yes, you're right; so what is this error that we are catching? How will it typically arise?

acrellin commented 2 years ago

This catches the case where no Authorization header was provided (or it was malformed) and the user is not already logged in

stefanv commented 2 years ago

Thanks!