简体   繁体   中英

How to find errors raised in Python's documentation?

I'm learning Python and don't know where I can find in the docs the potential errors raised by a dictionary or list call.

For instance:

d_maxtempm = d_summary[1]['maxtempm']
d_date = parsed_json['history']['date']

can raise a IndexOutOfBound or Key error ?

But where is the complete list so i can fully implement my error handling ?

The list of Built-in Exceptions can be found in the Python documentation.

list and dict are documented, too.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM