summaryrefslogtreecommitdiff
path: root/sphinx/util/inspect.py
Commit message (Collapse)AuthorAgeFilesLines
...
* | Merge branch '3.x'Takeshi KOMIYA2020-04-131-2/+11
|\ \ | |/
| * Fix #7422: autodoc: fails with ValueError when using autodoc_mock_importsTakeshi KOMIYA2020-04-081-2/+11
| |
* | Merge branch '3.x'Takeshi KOMIYA2020-04-061-15/+26
|\ \ | |/
| * Fix flake8 errorTakeshi KOMIYA2020-04-051-1/+1
| |
| * Merge branch '2.x' into 3.0.xTakeshi KOMIYA2020-04-051-15/+26
| |\
| | * Fix: autodoc: `__wrapped__` functions are not documented correctlyTerence D. Honles2020-02-271-14/+25
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Functions that are decorated with `@lru_cache` or other `functools` decorators may not even be detected as a function. This results in the documentation not having the `()` or even trying to render the function signature. This change updates the `sphinx.util.inspect` code to unwrap `__wrapped__` functions before determining if they can be documented. `@lru_cache` and its associated test is an example of a decorated function that is incorrectly identified as an attribute rather than a module level function and when rendering the signature (upon changing `isattributedescriptor`) the decorated function is still incorrectly identified as a C function. This change also renames the newly introduced `unwrap` as `unwrap_all` because it is different than the prexisting Python supplied `inspect.unwrap`. See `update_wrapper` "Changed in version 3.4" for more background: https://docs.python.org/3/library/functools.html#functools.update_wrapper
* | | Merge branch '3.x'Takeshi KOMIYA2020-03-231-0/+11
|\ \ \ | |/ /
| * | Fix a cyfunction was considered as an attribute descriptorTakeshi KOMIYA2020-03-221-0/+11
| | |
* | | Merge branch '3.x'Takeshi KOMIYA2020-03-101-0/+20
|\ \ \ | |/ /
| * | autodoc: Support singledispatch methodsTakeshi KOMIYA2020-03-071-0/+9
| | |
| * | Close #2815: autodoc: Support singledispatch functionsTakeshi KOMIYA2020-03-071-0/+11
| | |
* | | Deprecate codes for python 3.5Takeshi KOMIYA2020-03-071-1/+1
|/ /
* | Merge branch '2.4.x' into 3.xTakeshi KOMIYA2020-02-221-4/+17
|\ \ | |/
| * Fix #7189: autodoc: classmethod coroutines are not detectedTakeshi KOMIYA2020-02-221-4/+17
| |
* | Merge pull request #7155 from tk0miya/function_signature2Takeshi KOMIYA2020-02-221-0/+49
|\ \ | | | | | | py domain: Use AST parser to convert signature to doctree
| * | Add sphinx.util.inspect:signature_from_str()Takeshi KOMIYA2020-02-161-0/+49
| | |
* | | Merge branch '2.0'Takeshi KOMIYA2020-02-161-3/+3
|\ \ \ | | |/ | |/|
| * | Fix #7156: autodoc: separator for keyword only arguments is not shownTakeshi KOMIYA2020-02-161-3/+3
| | |
* | | refactor: Update type annotations in sphinx.util.*Takeshi KOMIYA2020-02-161-1/+1
| |/ |/|
* | Deprecate sphinx.util.inspect.getargspec()Takeshi KOMIYA2020-02-141-1/+3
| |
* | Merge branch '2.0'Takeshi KOMIYA2020-01-301-0/+4
|\ \ | |/
| * Merge branch '2.0' into 6418_autodoc_typehints_descriptionTakeshi KOMIYA2020-01-301-0/+2
| |\
| | * Deprecate sphinx.util.inspect:safe_getmembers()Takeshi KOMIYA2020-01-251-0/+2
| | |
| * | Add a new extension: sphinx.ext.autodoc.typehintsTakeshi KOMIYA2020-01-251-0/+2
| |/
* | Merge branch '2.0'Takeshi KOMIYA2020-01-191-34/+38
|\ \ | |/
| * Fix #7023: autodoc: nested partial functions are not listedTakeshi KOMIYA2020-01-171-6/+14
| |
| * Merge pull request #7012 from tk0miya/support_pep570Takeshi KOMIYA2020-01-111-5/+11
| |\ | | | | | | autodoc: Support Positional-Only Argument separator (PEP-570 compliant)
| | * autodoc: Support Positional-Only Argument separator (PEP-570 compliant)Takeshi KOMIYA2020-01-111-5/+11
| | |
| * | refactor: Simplify stringify_signature()Takeshi KOMIYA2020-01-111-23/+13
| |/
* | refactor: replace inspect.Parameter with ParameterTakeshi KOMIYA2020-01-111-11/+11
| |
* | Merge branch '2.0'Takeshi KOMIYA2020-01-111-6/+109
|\ \ | |/
| * refactor: Add sphinx.util.inspect.signature()Takeshi KOMIYA2020-01-091-6/+109
| | | | | | | | | | | | | | | | | | | | | | As a successor of sphinx.util.inspect.Singnature, this adds signature() function behaves like `inspect.signature()`. It is very similar to way of python's inspect module. In addition, this also adds stringify_annotation() helper to sphinx.util.inspect module. With these two functions, we can move to python's Signature object to represent function signatures perfectly. It's natural design for python developers than ever.
* | Fix flake8 violationsTakeshi KOMIYA2020-01-081-0/+1
| |
* | Merge branch '2.0'Takeshi KOMIYA2020-01-081-154/+20
|\ \ | |/
| * Add sphinx.util.typing:stringify() to represent annotations as stringTakeshi KOMIYA2020-01-051-155/+20
| |
* | Merge branch '2.0'Takeshi KOMIYA2020-01-011-2/+2
|\ \ | |/
| * A happy new year!Takeshi KOMIYA2020-01-011-1/+1
| |
| * mypy: Enable disallow_incomplete_defs flag for type checkingTakeshi KOMIYA2019-12-301-1/+1
| |
* | Merge branch '2.0'Takeshi KOMIYA2019-10-061-4/+4
|\ \ | |/
| * Fix mypy violations (for mypy-0.730)Takeshi KOMIYA2019-10-061-4/+4
| |
* | Merge branch '2.0'Takeshi KOMIYA2019-08-191-10/+21
|\ \ | |/
| * Fix #6605: autodoc: crashed when target code contains custom method-like objectsTakeshi KOMIYA2019-08-181-2/+5
| |
| * Merge branch '2.0' into 6574_annotation_for_varidic_paramsTakeshi KOMIYA2019-08-031-2/+2
| |\
| | * Fix #6589: autodoc: Formatting issues with autodoc_typehints='none'Takeshi KOMIYA2019-08-021-2/+2
| | |
| * | Merge branch '2.0' into 6574_annotation_for_varidic_paramsTakeshi KOMIYA2019-08-021-22/+13
| |\ \ | | |/
| * | Fix autodoc: missing type annotation for variadic and keyword parameters ↵Takeshi KOMIYA2019-07-131-6/+14
| | | | | | | | | | | | (refs: #6574)
* | | Merge branch '2.0'jfbu2019-08-011-22/+13
|\ \ \ | | |/ | |/|
| * | refactor: sphinx.util.inspect:Signature.format_annotation_old()Takeshi KOMIYA2019-07-141-22/+13
| |/
* | Merge branch '2.0'Takeshi KOMIYA2019-07-131-4/+4
|\ \ | |/
| * Merge branch '2.1.3' into 2.0Takeshi KOMIYA2019-07-131-4/+4
| |\