You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
What's the best way to show errors, in case they should occur?
I've tried to use PromptUtils.println(), but I can't seem to make it work.
Example code:
def add_supplier() -> None:
try:
new_supplier = read_supplier_df()
df = pd.concat([df, new_supplier])
df.to_csv(SUPPLIERS_FILE_PATH) # could fail if the directory is not writable
except Exception as ex:
PromptUtils(Screen()).println(ex) # Display the full exception
main_menu.append_item(FunctionItem("Add supplier", add_supplier))
The text was updated successfully, but these errors were encountered:
What's the best way to show errors, in case they should occur?
I've tried to use PromptUtils.println(), but I can't seem to make it work.
Example code:
The text was updated successfully, but these errors were encountered: