|
1 | 1 | # -*- coding: utf-8 -*-
|
2 |
| -# Autogenerated by Sphinx on Tue Jan 30 18:36:07 2018 |
| 2 | +# Autogenerated by Sphinx on Tue Feb 27 19:39:14 2018 |
3 | 3 | topics = {'assert': 'The "assert" statement\n'
|
4 | 4 | '**********************\n'
|
5 | 5 | '\n'
|
|
483 | 483 | '\n'
|
484 | 484 | 'object.__getattr__(self, name)\n'
|
485 | 485 | '\n'
|
486 |
| - ' Called when an attribute lookup has not found the ' |
487 |
| - 'attribute in the\n' |
488 |
| - ' usual places (i.e. it is not an instance attribute ' |
489 |
| - 'nor is it found\n' |
490 |
| - ' in the class tree for "self"). "name" is the ' |
491 |
| - 'attribute name. This\n' |
492 |
| - ' method should return the (computed) attribute value ' |
493 |
| - 'or raise an\n' |
494 |
| - ' "AttributeError" exception.\n' |
| 486 | + ' Called when the default attribute access fails with ' |
| 487 | + 'an\n' |
| 488 | + ' "AttributeError" (either "__getattribute__()" raises ' |
| 489 | + 'an\n' |
| 490 | + ' "AttributeError" because *name* is not an instance ' |
| 491 | + 'attribute or an\n' |
| 492 | + ' attribute in the class tree for "self"; or ' |
| 493 | + '"__get__()" of a *name*\n' |
| 494 | + ' property raises "AttributeError"). This method ' |
| 495 | + 'should either\n' |
| 496 | + ' return the (computed) attribute value or raise an ' |
| 497 | + '"AttributeError"\n' |
| 498 | + ' exception.\n' |
495 | 499 | '\n'
|
496 | 500 | ' Note that if the attribute is found through the '
|
497 | 501 | 'normal mechanism,\n'
|
|
4718 | 4722 | 'conversion] [":" format_spec] "}"\n'
|
4719 | 4723 | ' field_name ::= arg_name ("." attribute_name | '
|
4720 | 4724 | '"[" element_index "]")*\n'
|
4721 |
| - ' arg_name ::= [identifier | integer]\n' |
| 4725 | + ' arg_name ::= [identifier | digit+]\n' |
4722 | 4726 | ' attribute_name ::= identifier\n'
|
4723 |
| - ' element_index ::= integer | index_string\n' |
| 4727 | + ' element_index ::= digit+ | index_string\n' |
4724 | 4728 | ' index_string ::= <any source character except '
|
4725 | 4729 | '"]"> +\n'
|
4726 | 4730 | ' conversion ::= "r" | "s" | "a"\n'
|
|
4879 | 4883 | ' fill ::= <any character>\n'
|
4880 | 4884 | ' align ::= "<" | ">" | "=" | "^"\n'
|
4881 | 4885 | ' sign ::= "+" | "-" | " "\n'
|
4882 |
| - ' width ::= integer\n' |
| 4886 | + ' width ::= digit+\n' |
4883 | 4887 | ' grouping_option ::= "_" | ","\n'
|
4884 |
| - ' precision ::= integer\n' |
| 4888 | + ' precision ::= digit+\n' |
4885 | 4889 | ' type ::= "b" | "c" | "d" | "e" | "E" | "f" | '
|
4886 | 4890 | '"F" | "g" | "G" | "n" | "o" | "s" | "x" | "X" | "%"\n'
|
4887 | 4891 | '\n'
|
|
8057 | 8061 | '\n'
|
8058 | 8062 | 'object.__getattr__(self, name)\n'
|
8059 | 8063 | '\n'
|
8060 |
| - ' Called when an attribute lookup has not found the ' |
8061 |
| - 'attribute in the\n' |
8062 |
| - ' usual places (i.e. it is not an instance attribute nor is ' |
8063 |
| - 'it found\n' |
8064 |
| - ' in the class tree for "self"). "name" is the attribute ' |
8065 |
| - 'name. This\n' |
8066 |
| - ' method should return the (computed) attribute value or ' |
8067 |
| - 'raise an\n' |
8068 |
| - ' "AttributeError" exception.\n' |
| 8064 | + ' Called when the default attribute access fails with an\n' |
| 8065 | + ' "AttributeError" (either "__getattribute__()" raises an\n' |
| 8066 | + ' "AttributeError" because *name* is not an instance ' |
| 8067 | + 'attribute or an\n' |
| 8068 | + ' attribute in the class tree for "self"; or "__get__()" of ' |
| 8069 | + 'a *name*\n' |
| 8070 | + ' property raises "AttributeError"). This method should ' |
| 8071 | + 'either\n' |
| 8072 | + ' return the (computed) attribute value or raise an ' |
| 8073 | + '"AttributeError"\n' |
| 8074 | + ' exception.\n' |
8069 | 8075 | '\n'
|
8070 | 8076 | ' Note that if the attribute is found through the normal '
|
8071 | 8077 | 'mechanism,\n'
|
|
11599 | 11605 | '\n'
|
11600 | 11606 | ' Frame objects\n'
|
11601 | 11607 | ' Frame objects represent execution frames. They may occur in\n'
|
11602 |
| - ' traceback objects (see below).\n' |
| 11608 | + ' traceback objects (see below), and are also passed to ' |
| 11609 | + 'registered\n' |
| 11610 | + ' trace functions.\n' |
11603 | 11611 | '\n'
|
11604 | 11612 | ' Special read-only attributes: "f_back" is to the previous '
|
11605 | 11613 | 'stack\n'
|
@@ -11654,44 +11662,59 @@
|
11654 | 11662 | ' New in version 3.4.\n'
|
11655 | 11663 | '\n'
|
11656 | 11664 | ' Traceback objects\n'
|
11657 |
| - ' Traceback objects represent a stack trace of an exception. ' |
11658 |
| - 'A\n' |
11659 |
| - ' traceback object is created when an exception occurs. When ' |
| 11665 | + ' Traceback objects represent a stack trace of an ' |
| 11666 | + 'exception. A\n' |
| 11667 | + ' traceback object is implicitly created when an exception\n' |
| 11668 | + ' occurs, and may also be explicitly created by calling\n' |
| 11669 | + ' "types.TracebackType".\n' |
| 11670 | + '\n' |
| 11671 | + ' For implicitly created tracebacks, when the search for an\n' |
| 11672 | + ' exception handler unwinds the execution stack, at each\n' |
| 11673 | + ' unwound level a traceback object is inserted in front of ' |
11660 | 11674 | 'the\n'
|
11661 |
| - ' search for an exception handler unwinds the execution stack, ' |
11662 |
| - 'at\n' |
11663 |
| - ' each unwound level a traceback object is inserted in front ' |
11664 |
| - 'of\n' |
11665 |
| - ' the current traceback. When an exception handler is ' |
11666 |
| - 'entered,\n' |
11667 |
| - ' the stack trace is made available to the program. (See ' |
11668 |
| - 'section\n' |
11669 |
| - ' The try statement.) It is accessible as the third item of ' |
| 11675 | + ' current traceback. When an exception handler is entered, ' |
11670 | 11676 | 'the\n'
|
11671 |
| - ' tuple returned by "sys.exc_info()". When the program contains ' |
11672 |
| - 'no\n' |
11673 |
| - ' suitable handler, the stack trace is written (nicely ' |
11674 |
| - 'formatted)\n' |
11675 |
| - ' to the standard error stream; if the interpreter is ' |
11676 |
| - 'interactive,\n' |
11677 |
| - ' it is also made available to the user as ' |
11678 |
| - '"sys.last_traceback".\n' |
11679 |
| - '\n' |
11680 |
| - ' Special read-only attributes: "tb_next" is the next level in ' |
| 11677 | + ' stack trace is made available to the program. (See ' |
| 11678 | + 'section\n' |
| 11679 | + ' The try statement.) It is accessible as the third item of ' |
11681 | 11680 | 'the\n'
|
11682 |
| - ' stack trace (towards the frame where the exception occurred), ' |
11683 |
| - 'or\n' |
11684 |
| - ' "None" if there is no next level; "tb_frame" points to the\n' |
11685 |
| - ' execution frame of the current level; "tb_lineno" gives the ' |
11686 |
| - 'line\n' |
11687 |
| - ' number where the exception occurred; "tb_lasti" indicates ' |
| 11681 | + ' tuple returned by "sys.exc_info()", and as the\n' |
| 11682 | + ' "__traceback__" attribute of the caught exception.\n' |
| 11683 | + '\n' |
| 11684 | + ' When the program contains no suitable handler, the stack\n' |
| 11685 | + ' trace is written (nicely formatted) to the standard error\n' |
| 11686 | + ' stream; if the interpreter is interactive, it is also ' |
| 11687 | + 'made\n' |
| 11688 | + ' available to the user as "sys.last_traceback".\n' |
| 11689 | + '\n' |
| 11690 | + ' For explicitly created tracebacks, it is up to the creator ' |
| 11691 | + 'of\n' |
| 11692 | + ' the traceback to determine how the "tb_next" attributes\n' |
| 11693 | + ' should be linked to form a full stack trace.\n' |
| 11694 | + '\n' |
| 11695 | + ' Special read-only attributes: "tb_frame" points to the\n' |
| 11696 | + ' execution frame of the current level; "tb_lineno" gives ' |
11688 | 11697 | 'the\n'
|
11689 |
| - ' precise instruction. The line number and last instruction ' |
| 11698 | + ' line number where the exception occurred; "tb_lasti"\n' |
| 11699 | + ' indicates the precise instruction. The line number and ' |
| 11700 | + 'last\n' |
| 11701 | + ' instruction in the traceback may differ from the line ' |
| 11702 | + 'number\n' |
| 11703 | + ' of its frame object if the exception occurred in a "try"\n' |
| 11704 | + ' statement with no matching except clause or with a ' |
| 11705 | + 'finally\n' |
| 11706 | + ' clause.\n' |
| 11707 | + '\n' |
| 11708 | + ' Special writable attribute: "tb_next" is the next level ' |
11690 | 11709 | 'in\n'
|
11691 |
| - ' the traceback may differ from the line number of its frame\n' |
11692 |
| - ' object if the exception occurred in a "try" statement with ' |
11693 |
| - 'no\n' |
11694 |
| - ' matching except clause or with a finally clause.\n' |
| 11710 | + ' the stack trace (towards the frame where the exception\n' |
| 11711 | + ' occurred), or "None" if there is no next level.\n' |
| 11712 | + '\n' |
| 11713 | + ' Changed in version 3.7: Traceback objects can now be ' |
| 11714 | + 'explicitly\n' |
| 11715 | + ' instantiated from Python code, and the "tb_next" attribute ' |
| 11716 | + 'of\n' |
| 11717 | + ' existing instances can be updated.\n' |
11695 | 11718 | '\n'
|
11696 | 11719 | ' Slice objects\n'
|
11697 | 11720 | ' Slice objects are used to represent slices for '
|
|
0 commit comments