summaryrefslogtreecommitdiff
path: root/sphinx/domains/python.py
Commit message (Collapse)AuthorAgeFilesLines
* js/py nodes, update arglist renderingJakob Lykke Andersen2021-10-031-1/+2
|
* py nodes, Constant NoneJakob Lykke Andersen2021-10-021-0/+2
|
* py nodes, PyObject annoJakob Lykke Andersen2021-10-021-1/+9
|
* py nodes, get_signature_prefix cleanupJakob Lykke Andersen2021-10-021-4/+1
|
* py nodes, PyProperty get_signature_prefixJakob Lykke Andersen2021-10-021-6/+9
|
* py nodes, PyMethod get_signature_prefixJakob Lykke Andersen2021-10-021-13/+15
|
* py nodes, PyClassLike, get_signature_prefixJakob Lykke Andersen2021-10-021-3/+4
|
* py nodes, PyFunction get_signature_prefixJakob Lykke Andersen2021-10-021-3/+4
|
* py nodes, prep for get_signature_prefix changeJakob Lykke Andersen2021-10-021-3/+6
|
* py nodes, PyPropertyJakob Lykke Andersen2021-10-021-1/+4
|
* py nodes, PyAttribute valueJakob Lykke Andersen2021-10-021-1/+5
|
* py nodes, PyAttribute typeJakob Lykke Andersen2021-10-021-1/+4
|
* py nodes, PyVariable valueJakob Lykke Andersen2021-10-021-1/+5
|
* py nodes, PyVariable typeJakob Lykke Andersen2021-10-021-1/+3
|
* py nodes, arglistJakob Lykke Andersen2021-10-021-3/+3
|
* py nodes, TupleJakob Lykke Andersen2021-10-021-1/+3
|
* py nodes, ListJakob Lykke Andersen2021-10-021-1/+3
|
* py nodes, BitOrJakob Lykke Andersen2021-10-021-1/+3
|
* Fix typos discovered by codespellChristian Clauss2021-09-081-1/+1
|
* Fix #9576: py domain: Literal typehint was converted to a cross referenceTakeshi KOMIYA2021-09-031-2/+10
| | | | | The content of Literal typehint should not be converted to cross references.
* Fix #9585: py:property directive does not create a hyperlink for typesTakeshi KOMIYA2021-08-311-1/+2
|
* Cloase #9445: :py:property: directive now supports :classmethod: optionTakeshi KOMIYA2021-07-171-2/+6
| | | | | Since python 3.9, `classmethod` starts to support creating a "class property". This allows to describe it.
* Merge branch '4.x' into 9427Takeshi KOMIYA2021-07-111-22/+35
|\
| * fields, call roles instead of making a pending_xrefJakob Lykke Andersen2021-06-031-8/+18
| | | | | | | | Except for py which has mixins that assumes a single pending_xref
| * Close #9268: python_use_unqualified_type_names supports type fieldTakeshi KOMIYA2021-06-031-0/+10
| |
| * Fix #9280: py domain: "exceptions" module is not displayedTakeshi KOMIYA2021-05-301-6/+3
| | | | | | | | | | | | | | | | | | | | Since v0.2, python domain gives a special treatment for the exceptions module to suppress its name on documenting exception classes. It had been worthy on python2 era. But the module has been removed since python3. Therefore, the special treatment becomes harmful for user libraries. This removes it to render module names correctly. Note: Now we've only supported python3. So this is not incompatible.
| * Merge pull request #9258 from tk0miya/1874_piped_types_in_info-field-listTakeshi KOMIYA2021-05-231-1/+1
| |\ | | | | | | Close #1874: py domain: Support union types using `|` in info-field-list
| | * Close #1874: py domain: Support union types using `|` in info-field-listTakeshi KOMIYA2021-05-221-1/+1
| | |
| * | refactor: reduce calls of find_pending_xref_conditions (refs: #9240)Takeshi KOMIYA2021-05-221-4/+0
| |/ | | | | | | | | | | | | After #9246, `find_pending_xref_conditions()` should be only called from intended modules. At present, the Python Domain is the only module to call it intendedly. Therefore, this removes the needless calls of the utility function from "unintended" modules.
| * Merge branch '4.0.x' into 4.xTakeshi KOMIYA2021-05-111-3/+7
| |\
| * | refactor: Add Optional to type annotationsTakeshi KOMIYA2021-05-101-3/+3
| | |
* | | Closes #9418: Fix missing bracket for empty Callable annotations.Thomas Jungers2021-07-091-4/+8
| |/ |/|
* | Fix #9205: py domain: canonical option causes xref resolution errorTakeshi KOMIYA2021-05-111-3/+7
|/ | | | | | The :canonical: option causes "more than one target for cross-reference" warning because the class having the same name is registered.
* Merge pull request #9118 from chrisjsewell/fix-typingTakeshi KOMIYA2021-04-241-1/+1
|\ | | | | 🐛 FIX: `Config.__getitem__` typing
| * remove type: ignoreChris Sewell2021-04-231-1/+1
| |
* | Fix #9121: py domain: duplicated warning for canonical and aliasTakeshi KOMIYA2021-04-231-9/+17
|/ | | | | | A duplicated warning is emitted when both canonical and its alias objects are defined on the same document. But it should not be emitted because they're the same object, not conflicted.
* Fix #8127: py domain: Ellipsis in info-field-list causes nit-picky warningTakeshi KOMIYA2021-04-171-1/+1
| | | | | | | | | | On parsing the types, the leading dot of the ellipsis (...) is considered as a reference name. And its first dot is considered as a notation for relative type reference (ex. ".ClassName"). As a result, it was converted double dots unexpectedly. This changes the parsing rule to treat the ellipsis as a symbol, not a name.
* refactor: Use PEP-526 based variable annotation (sphinx.domains)Takeshi KOMIYA2021-03-231-14/+13
|
* Merge pull request #8991 from tk0miya/typing_OptionSpecTakeshi KOMIYA2021-03-151-11/+11
|\ | | | | refactor: Add a type alias for the option_spec of directives; OptionSpec
| * refactor: Add a type alias for the option_spec of directives; OptionSpecTakeshi KOMIYA2021-03-131-11/+11
| |
* | Merge pull request #8996 from tk0miya/7119_pending_xref_conditionsTakeshi KOMIYA2021-03-151-0/+4
|\ \ | | | | | | Fix #7119: autodoc: Broken doctree was generated by builtin_resolver
| * | Avoid a mypy warningTakeshi KOMIYA2021-03-151-1/+1
| | |
| * | Fix #7119: autodoc: Broken doctree was generated by builtin_resolverTakeshi KOMIYA2021-03-141-0/+4
| |/ | | | | | | | | The builtin_resolver() generates broken doctree unexpectedly if it contains pending_xref_condition nodes.
* | py domain: Add py:property directive to describe a property (refs: #7068)Takeshi KOMIYA2021-03-111-1/+52
|/
* Fix #7199: py domain: Add a new confval: python_use_unqualified_type_namesTakeshi KOMIYA2021-03-061-5/+32
| | | | | | Add a new config variable: python_use_unqualified_type_names. If enabled, it goes to suppress the module name of the python reference if it can be resolved.
* refactor: py domain: Put if-block for ast.Constant to the root levelTakeshi KOMIYA2021-02-031-6/+5
|
* Re-insert if isinstance(node, ast.Constant): into py _parse_annotationjfbu2021-02-031-0/+6
| | | | | | | | | | As master drop python 3.5 support, conditional if sys.version_info >= (3, 6): not needed anymore. This hunk had got lost in merge. modified: sphinx/domains/python.py
* Merge branch '3.x' into master_with_merged_3.xjfbu2021-02-021-7/+9
|\
| * py domain: Support type union operator (PEP-604) (refs: #8775)Takeshi KOMIYA2021-02-011-2/+9
| | | | | | | | | | | | Upgrade annotation parser for python domain to support type union operator introduced in PEP-604. It's available on all python interpreters.
* | Merge branch '3.x'Takeshi KOMIYA2021-01-081-1/+1
|\ \ | |/