Skip to content

Commit

Permalink
Adding error declaration
Browse files Browse the repository at this point in the history
  • Loading branch information
WillOfHeaven committed Mar 12, 2024
1 parent aaf617d commit 48f7247
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions app.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,7 @@
daily_data = data_IBM['Time Series (Daily)']
except KeyError:
print("Error: 'Time Series (Daily)' key not found in data")
st.write("Error: 'Time Series (Daily)' key not found in data")
# Handle the missing key here (e.g., display an error message, try a different source)
# You can exit the script or use a default value depending on your application logic
exit() # Example of exiting if the key is missing
Expand Down

0 comments on commit 48f7247

Please sign in to comment.