File tree Expand file tree Collapse file tree 2 files changed +4
-4
lines changed
Expand file tree Collapse file tree 2 files changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -1371,8 +1371,8 @@ finally:
13711371``` python
13721372except < exception> :
13731373except < exception> as < name> :
1374- except (< exception> , ... ):
1375- except (< exception> , ... ) as < name> :
1374+ except (< exception> , [ ... ] ):
1375+ except (< exception> , [ ... ] ) as < name> :
13761376```
13771377* ** Also catches subclasses of the exception.**
13781378* ** Use ` 'traceback.print_exc()' ` to print the error message to stderr.**
Original file line number Diff line number Diff line change 13041304</ ul >
13051305< div > < h3 id ="catchingexceptions "> Catching Exceptions</ h3 > < pre > < code class ="python language-python hljs "> < span class ="hljs-keyword "> except</ span > <exception>:
13061306< span class ="hljs-keyword "> except</ span > <exception> < span class ="hljs-keyword "> as</ span > <name>:
1307- < span class ="hljs-keyword "> except</ span > (<exception>, ...):
1308- < span class ="hljs-keyword "> except</ span > (<exception>, ...) < span class ="hljs-keyword "> as</ span > <name>:
1307+ < span class ="hljs-keyword "> except</ span > (<exception>, [ ...] ):
1308+ < span class ="hljs-keyword "> except</ span > (<exception>, [ ...] ) < span class ="hljs-keyword "> as</ span > <name>:
13091309</ code > </ pre > </ div >
13101310
13111311< ul >
You can’t perform that action at this time.
0 commit comments