General clean up
This commit is contained in:
11
app/main.py
11
app/main.py
@@ -352,6 +352,7 @@ async def fastapi_root():
|
|||||||
response_data['url_safe_string_8_bytes_3'] = secrets.token_urlsafe(8)
|
response_data['url_safe_string_8_bytes_3'] = secrets.token_urlsafe(8)
|
||||||
response_data['url_safe_string_8_bytes_4'] = secrets.token_urlsafe(8)
|
response_data['url_safe_string_8_bytes_4'] = secrets.token_urlsafe(8)
|
||||||
response_data['url_safe_string_8_bytes_5'] = secrets.token_urlsafe(8)
|
response_data['url_safe_string_8_bytes_5'] = secrets.token_urlsafe(8)
|
||||||
|
|
||||||
response_data['url_safe_string_16_bytes_1'] = secrets.token_urlsafe(16)
|
response_data['url_safe_string_16_bytes_1'] = secrets.token_urlsafe(16)
|
||||||
response_data['url_safe_string_16_bytes_2'] = secrets.token_urlsafe(16)
|
response_data['url_safe_string_16_bytes_2'] = secrets.token_urlsafe(16)
|
||||||
response_data['url_safe_string_16_bytes_3'] = secrets.token_urlsafe(16)
|
response_data['url_safe_string_16_bytes_3'] = secrets.token_urlsafe(16)
|
||||||
@@ -368,14 +369,14 @@ async def fastapi_root():
|
|||||||
# ### END ### API Main ### fastapi_root() ###
|
# ### END ### API Main ### fastapi_root() ###
|
||||||
|
|
||||||
|
|
||||||
# ### BEGIN ### API Main ### quick_test() ###
|
# ### BEGIN ### API Main ### sql_test() ###
|
||||||
# ### TEST TEST TEST ### #
|
# ### TEST TEST TEST ### #
|
||||||
@app.get('/quick_test', tags=['Testing'], response_class=PlainTextResponse)
|
@app.get('/sql_test', tags=['Testing'], response_class=PlainTextResponse)
|
||||||
async def quick_test():
|
async def sql_test():
|
||||||
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARN, WARNING, ERROR, EXCEPTION, CRITICAL
|
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARN, WARNING, ERROR, EXCEPTION, CRITICAL
|
||||||
log.debug(locals())
|
log.debug(locals())
|
||||||
|
|
||||||
log.info('Getting all accounts...')
|
log.info('Getting all accounts from DB...')
|
||||||
|
|
||||||
sql = text(
|
sql = text(
|
||||||
"""
|
"""
|
||||||
@@ -405,4 +406,4 @@ async def quick_test():
|
|||||||
response_data['data'] = record_li
|
response_data['data'] = record_li
|
||||||
|
|
||||||
return json.dumps(response_data, indent=4) # , sort_keys=True
|
return json.dumps(response_data, indent=4) # , sort_keys=True
|
||||||
# ### END ### API Main ### quick_test() ###
|
# ### END ### API Main ### sql_test() ###
|
||||||
|
|||||||
Reference in New Issue
Block a user