mirror of
https://github.com/firestar5683/StarPilot.git
synced 2026-12-02 03:45:55 +08:00
tools: point unauthorized error at op auth (#39405)
This commit is contained in:
@@ -35,7 +35,7 @@ class CommaApi:
|
||||
resp_json = resp.json()
|
||||
if isinstance(resp_json, dict) and resp_json.get('error'):
|
||||
if resp.status_code in [401, 403]:
|
||||
raise UnauthorizedError('Unauthorized. Authenticate with openpilot/tools/lib/auth.py')
|
||||
raise UnauthorizedError('Unauthorized. Authenticate with op auth')
|
||||
|
||||
e = APIError(str(resp.status_code) + ":" + resp_json.get('description', str(resp_json['error'])))
|
||||
e.status_code = resp.status_code
|
||||
|
||||
Reference in New Issue
Block a user