Skip to content

Commit 404561d

Browse files
committed
Fixed complaint about logging
1 parent 01d687b commit 404561d

File tree

2 files changed

+3
-6
lines changed

2 files changed

+3
-6
lines changed

.pylintrc

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -342,9 +342,6 @@ redefining-builtins-modules=six,six.moves,past.builtins,future.builtins,functool
342342
# function parameter format
343343
logging-modules=logging,absl.logging,tensorflow.io.logging
344344

345-
# MrMat - We like f-strings for logging
346-
logging-format-style=new
347-
348345

349346
[SIMILARITIES]
350347

mrmat_python_api_flask/client.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -98,7 +98,7 @@ def oidc_check_auth(config: Dict, discovery: Dict, device_auth: Dict):
9898
raise ClientException(msg=body['error_description'])
9999
elif resp.status_code == 200:
100100
return resp.json()
101-
log.info('Waiting for %d seconds', wait)
101+
log.info('Waiting for %s seconds', wait)
102102
sleep(wait)
103103

104104

@@ -200,7 +200,7 @@ def main(argv=None) -> int:
200200
raise ClientException(msg='No expires_in in device_auth')
201201

202202
# Adding the user code to the URL is convenient, but not as secure as it could be
203-
log.info('Please visit %s within %d seconds and enter code %s. Or just visit %s',
203+
log.info('Please visit %s within %s seconds and enter code %s. Or just visit %s',
204204
device_auth['verification_uri'],
205205
device_auth['expires_in'],
206206
device_auth['user_code'],
@@ -214,7 +214,7 @@ def main(argv=None) -> int:
214214

215215
resp = requests.get(f'http://{args.host}:{args.port}/api/greeting/v3/',
216216
headers={'Authorization': f'Bearer {auth["id_token"]}'})
217-
log.info('Status Code: %d', resp.status_code)
217+
log.info('Status Code: %s', resp.status_code)
218218
log.info(resp.content)
219219

220220
return 0

0 commit comments

Comments
 (0)