Removing debugging. Changing it to INFO in many locations.

This commit is contained in:
Scott Idem
2026-01-20 19:23:30 -05:00
parent c795f42290
commit 45ca81a3e3
24 changed files with 76 additions and 76 deletions

View File

@@ -110,7 +110,7 @@ def create_update_address_obj_v4(
fail_any: bool = False, # Fail if any thing goes wrong for sub objects fail_any: bool = False, # Fail if any thing goes wrong for sub objects
return_outline: bool = False, return_outline: bool = False,
) -> int|bool: ) -> int|bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
log.info('Checking requirements...') log.info('Checking requirements...')
@@ -172,7 +172,7 @@ def create_update_address_obj_v4(
address_dict['for_id'] = for_id address_dict['for_id'] = for_id
try: try:
address_obj = Address_Base(**address_dict) address_obj = Address_Base(**address_dict)
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(address_obj) log.debug(address_obj)
except ValidationError as e: except ValidationError as e:
log.error(e.json()) log.error(e.json())
@@ -231,7 +231,7 @@ def create_address_obj(
for_id: int|str = None, for_id: int|str = None,
fail_any: bool = False, # Fail if any thing goes wrong for sub objects fail_any: bool = False, # Fail if any thing goes wrong for sub objects
) -> int|bool: ) -> int|bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# ### SECTION ### Secondary data validation # ### SECTION ### Secondary data validation
@@ -312,7 +312,7 @@ def update_address_obj(
create_sub_obj: bool = False, create_sub_obj: bool = False,
fail_any: bool = False, # Fail if any thing goes wrong for sub objects fail_any: bool = False, # Fail if any thing goes wrong for sub objects
) -> bool: ) -> bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# ### SECTION ### Secondary data validation # ### SECTION ### Secondary data validation
@@ -381,7 +381,7 @@ def create_update_address_obj(
process_address: bool = False, process_address: bool = False,
process_organization: bool = False, process_organization: bool = False,
) -> bool: ) -> bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if address_id: if address_id:

View File

@@ -224,7 +224,7 @@ def create_update_contact_obj_v4(
contact_dict['for_id'] = for_id contact_dict['for_id'] = for_id
try: try:
contact_obj = Contact_Base(**contact_dict) contact_obj = Contact_Base(**contact_dict)
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(contact_obj) log.debug(contact_obj)
except ValidationError as e: except ValidationError as e:
log.error(e.json()) log.error(e.json())
@@ -540,7 +540,7 @@ def create_update_contact_obj(
process_address: bool = False, process_address: bool = False,
process_organization: bool = False, process_organization: bool = False,
) -> bool: ) -> bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if contact_id: if contact_id:

View File

@@ -70,7 +70,7 @@ def load_event_abstract_obj(
# Updated 2023-03-20 # Updated 2023-03-20
if inc_event_file_list: if inc_event_file_list:
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.info('Need to include event file list...') log.info('Need to include event file list...')
from app.methods.event_file_methods import get_event_file_rec_list, load_event_file_obj from app.methods.event_file_methods import get_event_file_rec_list, load_event_file_obj
@@ -123,7 +123,7 @@ def load_event_abstract_obj(
log.debug(event_person_obj) log.debug(event_person_obj)
event_abstract_obj.event_person = event_person_obj event_abstract_obj.event_person = event_person_obj
else: else:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(event_person_obj) log.debug(event_person_obj)
event_abstract_obj.event_person = None event_abstract_obj.event_person = None
log.setLevel(logging.WARNING) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.WARNING) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
@@ -227,7 +227,7 @@ def get_event_abstract_rec_list(
ORDER BY event_abstract.priority DESC, event_abstract.sort DESC, event_abstract.name ASC, `event_abstract`.created_on DESC, `event_abstract`.updated_on DESC ORDER BY event_abstract.priority DESC, event_abstract.sort DESC, event_abstract.name ASC, `event_abstract`.created_on DESC, `event_abstract`.updated_on DESC
{sql_limit}; {sql_limit};
""" """
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(sql) log.debug(sql)
if event_abstract_rec_li_result := sql_select(data=data, sql=sql, as_list=True): if event_abstract_rec_li_result := sql_select(data=data, sql=sql, as_list=True):
@@ -329,7 +329,7 @@ def create_update_event_abstract_obj_old(
fail_any: bool = False, # Fail if any thing goes wrong for sub objects fail_any: bool = False, # Fail if any thing goes wrong for sub objects
return_outline: bool = False, return_outline: bool = False,
) -> int|bool: ) -> int|bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
log.info('Checking requirements...') log.info('Checking requirements...')
@@ -379,7 +379,7 @@ def create_update_event_abstract_obj_old(
event_abstract_dict['event_person_id'] = event_person_id event_abstract_dict['event_person_id'] = event_person_id
try: try:
event_abstract_obj = Event_Abstract_In(**event_abstract_dict) event_abstract_obj = Event_Abstract_In(**event_abstract_dict)
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(event_abstract_obj) log.debug(event_abstract_obj)
except ValidationError as e: except ValidationError as e:
log.error(e.json()) log.error(e.json())

View File

@@ -77,7 +77,7 @@ def load_event_obj_list(
""" """
if event_rec_li_result := sql_select(data=data, sql=sql, as_list=True): if event_rec_li_result := sql_select(data=data, sql=sql, as_list=True):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(event_rec_li_result) log.debug(event_rec_li_result)
event_result_li = [] event_result_li = []
for event_rec in event_rec_li_result: for event_rec in event_rec_li_result:
@@ -113,7 +113,7 @@ def load_event_obj_list(
event_result_li.append(None) event_result_li.append(None)
log.debug(event_result_li) log.debug(event_result_li)
else: else:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(event_rec_li_result) log.debug(event_rec_li_result)
event_result_li = [] event_result_li = []
log.setLevel(logging.WARNING) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.WARNING) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL

View File

@@ -34,7 +34,7 @@ def load_organization_obj(
if organization_rec := sql_select(table_name='v_organization', record_id=organization_id): pass if organization_rec := sql_select(table_name='v_organization', record_id=organization_id): pass
else: return False else: return False
#log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL #log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(organization_rec) log.debug(organization_rec)
try: try:
@@ -114,7 +114,7 @@ def get_organization_rec_list(
organization_rec_li = organization_rec_li_result organization_rec_li = organization_rec_li_result
else: else:
organization_rec_li = [] organization_rec_li = []
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(organization_rec_li_result) log.debug(organization_rec_li_result)
return organization_rec_li return organization_rec_li
@@ -154,11 +154,11 @@ def update_organization_obj(
account_id = contact_obj_in.account_id, account_id = contact_obj_in.account_id,
contact_dict_obj=contact_obj_in, contact_dict_obj=contact_obj_in,
): ):
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(contact_obj_in_result) log.debug(contact_obj_in_result)
organization_obj_up.contact_id = contact_obj_in_result organization_obj_up.contact_id = contact_obj_in_result
else: else:
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(contact_obj_in_result) log.debug(contact_obj_in_result)
return False return False
@@ -180,7 +180,7 @@ def create_update_organization_obj(
organization_obj: Organization_Base, organization_obj: Organization_Base,
process_contact: bool = False, process_contact: bool = False,
) -> bool: ) -> bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if organization_id: if organization_id:

View File

@@ -100,7 +100,7 @@ def update_site_obj(
site_obj_up: Site_Base, site_obj_up: Site_Base,
create_sub_obj: bool = False, create_sub_obj: bool = False,
) -> bool: ) -> bool:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if site_id := redis_lookup_id_random(record_id_random=site_id, table_name='site'): pass if site_id := redis_lookup_id_random(record_id_random=site_id, table_name='site'): pass

View File

@@ -99,7 +99,7 @@ async def get_account_obj_li(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# Updated 2021-09-28 # Updated 2021-09-28
@@ -293,12 +293,12 @@ async def get_account_obj(
inc_user_list = inc_user_list, inc_user_list = inc_user_list,
): ):
if isinstance(account_result, dict): if isinstance(account_result, dict):
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.info('Result is a dict') log.info('Result is a dict')
response_data = account_result response_data = account_result
log.debug(response_data) log.debug(response_data)
else: else:
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# print('---------------------------') # print('---------------------------')
log.info('Result is probably an object model') log.info('Result is probably an object model')
response_data = account_result response_data = account_result
@@ -345,7 +345,7 @@ async def get_account_cfg_obj(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if account_id := redis_lookup_id_random(record_id_random=commons.x_account_id, table_name='account'): pass if account_id := redis_lookup_id_random(record_id_random=commons.x_account_id, table_name='account'): pass
@@ -381,6 +381,6 @@ async def get_account_cfg_obj(
# by_alias=True, # by_alias=True,
# exclude_unset=True, # exclude_unset=True,
# ) # )
# #log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # #log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# log.debug(result) # log.debug(result)
# return result # return result

View File

@@ -30,7 +30,7 @@ async def post_address_obj(
exclude_none: Optional[bool] = True, exclude_none: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'address' obj_type = 'address'
@@ -55,7 +55,7 @@ async def patch_address_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
address_obj_type = 'address' address_obj_type = 'address'

View File

@@ -32,7 +32,7 @@ def convert_obj_type(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# ### SECTION ### Get the field map for the object type # ### SECTION ### Get the field map for the object type

View File

@@ -62,13 +62,13 @@ async def authenticate_passcode(
if matched_role: if matched_role:
log.info(f"Auth Success: Verified '{matched_role}' passcode for site {site_id}") log.info(f"Auth Success: Verified '{matched_role}' passcode for site {site_id}")
# 4. Resolve Account Context # 4. Resolve Account Context
account_id_random = record.get('account_id_random') account_id_random = record.get('account_id_random')
if not account_id_random: if not account_id_random:
if account_id_int := record.get('account_id'): if account_id_int := record.get('account_id'):
account_id_random = get_id_random(record_id=account_id_int, table_name='account') account_id_random = get_id_random(record_id=account_id_int, table_name='account')
# 5. Mint JWT # 5. Mint JWT
payload = { payload = {
'account_id': account_id_random, 'account_id': account_id_random,
@@ -81,13 +81,13 @@ async def authenticate_passcode(
'role': matched_role 'role': matched_role
}) })
} }
token = sign_jwt( token = sign_jwt(
secret_key=settings.JWT_KEY, secret_key=settings.JWT_KEY,
ttl=3600 * 24, # 24 hour session ttl=3600 * 24, # 24 hour session
**payload **payload
) )
return mk_resp(data={'jwt': token, 'account_id': account_id_random, 'role': matched_role}, response=response) return mk_resp(data={'jwt': token, 'account_id': account_id_random, 'role': matched_role}, response=response)
else: else:
log.warning(f"Auth Failed: Invalid passcode for site {site_id}") log.warning(f"Auth Failed: Invalid passcode for site {site_id}")
@@ -174,11 +174,11 @@ async def request_jwt(
return mk_resp(data=False, status_code=400, response=response) # Bad Request return mk_resp(data=False, status_code=400, response=response) # Bad Request
# SECURITY PATCH: Prevent public API key from minting privileged tokens # SECURITY PATCH: Prevent public API key from minting privileged tokens
# If we are using the default system key (settings.JWT_KEY) but NO external signing key was provided # If we are using the default system key (settings.JWT_KEY) but NO external signing key was provided
# (i.e. access via public API Key), we must NOT allow minting account-level privileges. # (i.e. access via public API Key), we must NOT allow minting account-level privileges.
# UNLESS we are renewing a valid existing token (handled by x_aether_jwt renewal logic below). # UNLESS we are renewing a valid existing token (handled by x_aether_jwt renewal logic below).
if not x_aether_signing_key and not x_aether_jwt: if not x_aether_signing_key and not x_aether_jwt:
if account_id or person_id or user_id: if account_id or person_id or user_id:
log.warning("Security: Attempt to mint privileged JWT without signing key. Downgrading to Guest.") log.warning("Security: Attempt to mint privileged JWT without signing key. Downgrading to Guest.")
account_id = None account_id = None
person_id = None person_id = None
@@ -340,7 +340,7 @@ async def create_jitsi_jwt(
Generates a Jitsi-specific JWT token for authentication. Generates a Jitsi-specific JWT token for authentication.
The token includes claims to set the user's name, email, and moderator status. The token includes claims to set the user's name, email, and moderator status.
""" """
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# log.debug(f"Received Jitsi token request: {request_data.model_dump_json(indent=2)}") # log.debug(f"Received Jitsi token request: {request_data.model_dump_json(indent=2)}")
log.debug(f"Received Jitsi token request: {request_data}") log.debug(f"Received Jitsi token request: {request_data}")
@@ -701,7 +701,7 @@ async def create_jitsi_jwt(
Generates a Jitsi-specific JWT token for authentication. Generates a Jitsi-specific JWT token for authentication.
The token includes claims to set the user's name, email, and moderator status. The token includes claims to set the user's name, email, and moderator status.
""" """
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# log.debug(f"Received Jitsi token request: {request_data.model_dump_json(indent=2)}") # log.debug(f"Received Jitsi token request: {request_data.model_dump_json(indent=2)}")
log.debug(f"Received Jitsi token request: {request_data}") log.debug(f"Received Jitsi token request: {request_data}")

View File

@@ -1324,11 +1324,11 @@ def post_obj_template(
base_name = obj_type_kv_li[obj_type]['base_name'] base_name = obj_type_kv_li[obj_type]['base_name']
if sql_insert_result := sql_insert(table_name=table_name_insert, data=obj_data, id_random_length=id_random_length): if sql_insert_result := sql_insert(table_name=table_name_insert, data=obj_data, id_random_length=id_random_length):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(sql_insert_result) log.debug(sql_insert_result)
obj_id = sql_insert_result obj_id = sql_insert_result
else: else:
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(sql_insert_result) log.debug(sql_insert_result)
return mk_resp(data=False, status_code=400, response=response) return mk_resp(data=False, status_code=400, response=response)

View File

@@ -27,7 +27,7 @@ async def post_cont_edu_cert_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'cont_edu_cert' obj_type = 'cont_edu_cert'
@@ -214,7 +214,7 @@ async def get_account_obj_cont_edu_cert_list(
else: return mk_resp(data=None, status_code=404) else: return mk_resp(data=None, status_code=404)
response_data = None response_data = None
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# Updated 2021-07-28 # Updated 2021-07-28
if cont_edu_cert_rec_list_result := get_cont_edu_cert_rec_list( if cont_edu_cert_rec_list_result := get_cont_edu_cert_rec_list(

View File

@@ -27,7 +27,7 @@ async def post_cont_edu_cert_person_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'cont_edu_cert_person' obj_type = 'cont_edu_cert_person'
@@ -191,7 +191,7 @@ async def search_cont_edu_cert_person_obj_li(
exclude_unset: bool = True, exclude_unset: bool = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if account_id := redis_lookup_id_random(record_id_random=x_account_id, table_name='account'): pass if account_id := redis_lookup_id_random(record_id_random=x_account_id, table_name='account'): pass
@@ -333,7 +333,7 @@ async def get_account_obj_cont_edu_cert_person_list(
else: return mk_resp(data=None, status_code=404, response=response) else: return mk_resp(data=None, status_code=404, response=response)
response_data = None response_data = None
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# Updated 2021-07-28 # Updated 2021-07-28
if cont_edu_cert_person_rec_list_result := get_cont_edu_cert_person_rec_list( if cont_edu_cert_person_rec_list_result := get_cont_edu_cert_person_rec_list(
@@ -375,7 +375,7 @@ async def get_person_obj_cont_edu_cert_person_list(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if person_id := redis_lookup_id_random(record_id_random=person_id, table_name='person'): pass if person_id := redis_lookup_id_random(record_id_random=person_id, table_name='person'): pass
@@ -431,7 +431,7 @@ async def get_cont_edu_cert_obj_cont_edu_cert_person_list(
else: return mk_resp(data=None, status_code=404, response=response) else: return mk_resp(data=None, status_code=404, response=response)
response_data = None response_data = None
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# Updated 2021-07-28 # Updated 2021-07-28
if cont_edu_cert_person_rec_list_result := get_cont_edu_cert_person_rec_list( if cont_edu_cert_person_rec_list_result := get_cont_edu_cert_person_rec_list(

View File

@@ -30,7 +30,7 @@ async def post_stripe_log_obj(
commons: Common_Route_Params_Min = Depends(common_route_params_min), commons: Common_Route_Params_Min = Depends(common_route_params_min),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'stripe_log' obj_type = 'stripe_log'

View File

@@ -37,7 +37,7 @@ async def post_event_abstract_obj(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_id := redis_lookup_id_random(record_id_random=event_id, table_name='event'): pass if event_id := redis_lookup_id_random(record_id_random=event_id, table_name='event'): pass

View File

@@ -28,7 +28,7 @@ async def post_event_badge_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'event_badge' obj_type = 'event_badge'
@@ -466,7 +466,7 @@ async def get_account_obj_event_badge_list(
else: return mk_resp(data=None, status_code=404, response=response) else: return mk_resp(data=None, status_code=404, response=response)
response_data = None response_data = None
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# Updated 2021-07-28 # Updated 2021-07-28
# from app.methods.event_badge_methods import get_event_badge_rec_list, load_event_badge_obj # from app.methods.event_badge_methods import get_event_badge_rec_list, load_event_badge_obj
@@ -511,14 +511,14 @@ async def get_event_obj_event_badge_list(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_id := redis_lookup_id_random(record_id_random=event_id, table_name='event'): pass if event_id := redis_lookup_id_random(record_id_random=event_id, table_name='event'): pass
else: return mk_resp(data=None, status_code=404, response=commons.response) else: return mk_resp(data=None, status_code=404, response=commons.response)
response_data = None response_data = None
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# Updated 2021-07-28 # Updated 2021-07-28
if event_badge_rec_list_result := get_event_badge_rec_list( if event_badge_rec_list_result := get_event_badge_rec_list(

View File

@@ -142,7 +142,7 @@ async def get_event_device_obj(
# commons: Common_Route_Params = Depends(common_route_params), # commons: Common_Route_Params = Depends(common_route_params),
commons: Common_Route_Params_No_Account_ID = Depends(common_route_params_no_account_id), commons: Common_Route_Params_No_Account_ID = Depends(common_route_params_no_account_id),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
# ### SECTION ### Secondary data validation # ### SECTION ### Secondary data validation

View File

@@ -389,7 +389,7 @@ async def get_event_exhibit_obj_tracking_list(
else: else:
event_exhibit_tracking_result_list.append(None) event_exhibit_tracking_result_list.append(None)
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
column_name_li = [ column_name_li = [
# 'event_exhibit_tracking_id_random', # 'event_exhibit_tracking_id_random',
@@ -496,7 +496,7 @@ async def get_event_exhibit_obj_tracking_list(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_exhibit_id := redis_lookup_id_random(record_id_random=event_exhibit_id, table_name='event_exhibit'): pass if event_exhibit_id := redis_lookup_id_random(record_id_random=event_exhibit_id, table_name='event_exhibit'): pass
@@ -575,7 +575,7 @@ async def lookup_event_badge_id_tracking(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_exhibit_id := redis_lookup_id_random(record_id_random=event_exhibit_id, table_name='event_exhibit'): pass if event_exhibit_id := redis_lookup_id_random(record_id_random=event_exhibit_id, table_name='event_exhibit'): pass

View File

@@ -160,7 +160,7 @@ async def patch_event_file_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'event_file' obj_type = 'event_file'
@@ -353,7 +353,7 @@ async def get_event_file_obj(
# commons: Common_Route_Params = Depends(common_route_params), # commons: Common_Route_Params = Depends(common_route_params),
# ): # ):
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# log.debug(locals()) # log.debug(locals())
# if event_file_id := redis_lookup_id_random(record_id_random=event_file_id, table_name='event_file'): pass # if event_file_id := redis_lookup_id_random(record_id_random=event_file_id, table_name='event_file'): pass
@@ -400,7 +400,7 @@ async def delete_event_file_obj_v2(
commons: Common_Route_Params = Depends(common_route_params), commons: Common_Route_Params = Depends(common_route_params),
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_file_id := redis_lookup_id_random(record_id_random=event_file_id, table_name='event_file'): pass if event_file_id := redis_lookup_id_random(record_id_random=event_file_id, table_name='event_file'): pass
@@ -409,7 +409,7 @@ async def delete_event_file_obj_v2(
if event_file_obj := load_event_file_obj( if event_file_obj := load_event_file_obj(
event_file_id = event_file_id, event_file_id = event_file_id,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
# event_file_dict = event_file_obj.dict(by_alias=by_alias, exclude_unset=exclude_unset) # event_file_dict = event_file_obj.dict(by_alias=by_alias, exclude_unset=exclude_unset)
log.info('Event File loaded') log.info('Event File loaded')
log.debug(event_file_obj) log.debug(event_file_obj)
@@ -432,7 +432,7 @@ async def delete_event_file_obj_v2(
link_to_type = for_type link_to_type = for_type
link_to_id = for_id link_to_id = for_id
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(f'Event File ID: {event_file_id}') log.debug(f'Event File ID: {event_file_id}')
if handle_delete_event_file(event_file_id=event_file_id): if handle_delete_event_file(event_file_id=event_file_id):
if delete_hosted_file: pass if delete_hosted_file: pass

View File

@@ -167,7 +167,7 @@ async def v2_post_event_person_new(
exclude_unset: bool = True, exclude_unset: bool = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
log.debug(event_person_new_init) log.debug(event_person_new_init)
@@ -229,7 +229,7 @@ async def v2_post_event_person_new(
inc_address = True, inc_address = True,
inc_organization = True, inc_organization = True,
) )
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL # log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(person_obj) log.debug(person_obj)
else: else:
log.debug('A new person was not created') log.debug('A new person was not created')
@@ -245,11 +245,11 @@ async def v2_post_event_person_new(
# user_new['contact_id_random'] = person_obj.contact.id_random # REMOVE: No longer used # user_new['contact_id_random'] = person_obj.contact.id_random # REMOVE: No longer used
# user_new['person_id_random'] = person_obj.id_random # REMOVE: No longer used # user_new['person_id_random'] = person_obj.id_random # REMOVE: No longer used
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(user_new) log.debug(user_new)
user_obj_new = User_New_Base(**user_new) user_obj_new = User_New_Base(**user_new)
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(user_obj_new) log.debug(user_obj_new)
user_id = None user_id = None
@@ -261,7 +261,7 @@ async def v2_post_event_person_new(
elif isinstance(create_user_obj_result, int): elif isinstance(create_user_obj_result, int):
user_id = create_user_obj_result user_id = create_user_obj_result
user_obj = load_user_obj(user_id=user_id) # Not including roles, contact, or organization user_obj = load_user_obj(user_id=user_id) # Not including roles, contact, or organization
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(user_obj) log.debug(user_obj)
else: else:
log.debug('A new user was not created') log.debug('A new user was not created')
@@ -404,7 +404,7 @@ async def get_event_person_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_person_id := redis_lookup_id_random(record_id_random=event_person_id, table_name='event_person'): pass if event_person_id := redis_lookup_id_random(record_id_random=event_person_id, table_name='event_person'): pass

View File

@@ -132,7 +132,7 @@ async def get_event_presenter_obj_li(
exclude_unset: bool = True, exclude_unset: bool = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
data = {} data = {}

View File

@@ -110,7 +110,7 @@ async def get_event_registration_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if event_registration_id := redis_lookup_id_random(record_id_random=event_registration_id, table_name='event_registration'): pass if event_registration_id := redis_lookup_id_random(record_id_random=event_registration_id, table_name='event_registration'): pass

View File

@@ -52,7 +52,7 @@ async def patch_membership_group_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'membership_group' obj_type = 'membership_group'
@@ -115,7 +115,7 @@ async def get_account_membership_group_obj_li(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if account_id := redis_lookup_id_random(record_id_random=account_id, table_name='account'): pass if account_id := redis_lookup_id_random(record_id_random=account_id, table_name='account'): pass
@@ -173,7 +173,7 @@ async def lookup_membership_group_obj(
exclude_unset: bool = True, exclude_unset: bool = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'membership_group' obj_type = 'membership_group'
@@ -181,7 +181,7 @@ async def lookup_membership_group_obj(
if for_obj_id := redis_lookup_id_random(record_id_random=for_obj_id, table_name=for_obj_type): pass if for_obj_id := redis_lookup_id_random(record_id_random=for_obj_id, table_name=for_obj_type): pass
else: return mk_resp(data=False, status_code=404, response=response) # Not Found else: return mk_resp(data=False, status_code=404, response=response) # Not Found
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
data = {} data = {}
as_list = False as_list = False
@@ -270,7 +270,7 @@ async def get_membership_group_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
if membership_group_id := redis_lookup_id_random(record_id_random=membership_group_id, table_name='membership_group'): pass if membership_group_id := redis_lookup_id_random(record_id_random=membership_group_id, table_name='membership_group'): pass

View File

@@ -29,7 +29,7 @@ async def post_order_cart_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
obj_type = 'order_cart' obj_type = 'order_cart'
@@ -59,7 +59,7 @@ async def patch_order_cart_obj(
exclude_unset: Optional[bool] = True, exclude_unset: Optional[bool] = True,
response: Response = Response, response: Response = Response,
): ):
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(locals()) log.debug(locals())
log.debug(order_cart_obj) log.debug(order_cart_obj)
@@ -135,7 +135,7 @@ async def lookup_order_cart_obj(
if for_obj_id := redis_lookup_id_random(record_id_random=for_obj_id, table_name=for_obj_type): pass if for_obj_id := redis_lookup_id_random(record_id_random=for_obj_id, table_name=for_obj_type): pass
else: return mk_resp(data=False, status_code=404, response=response) # Not Found else: return mk_resp(data=False, status_code=404, response=response) # Not Found
log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL log.setLevel(logging.INFO) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
data = {} data = {}
as_list = False as_list = False