summaryrefslogtreecommitdiff
path: root/numpy/typing
Commit message (Collapse)AuthorAgeFilesLines
...
* | MAINT: Replace the old `_NestedSequence` union and remove `_RecursiveSequence`Bas van Beek2021-09-194-17/+26
| |
* | ENH: Add a protocol for representing nested sequencesBas van Beek2021-09-192-0/+94
| |
* | MAINT: Let `eig` and `eigvals` return a union for real inputsBas van Beek2021-09-181-4/+4
| | | | | | | | | | | | Whether an array of a `floating` or `complexfloating` dtype is returned depends on the values within in the supplied matrix. Co-Authored-By: Kevin Sheppard <bashtage@users.noreply.github.com>
* | TST: Add typing tests for `np.linalg`Bas van Beek2021-09-172-0/+145
| |
* | DOC: Fix the module names of `numpy.typing` objectsBas van Beek2021-09-161-0/+2
|/
* MAINT: Mark type-check-only ufunc subclasses as ufunc aliases during runtimeBas van Beek2021-09-091-7/+10
|
* Merge pull request #19803 from BvB93/is_integerCharles Harris2021-09-022-1/+2
|\ | | | | ENH: Add `is_integer` to `np.floating` & `np.integer`
| * ENH: Add `integer.is_integer`Bas van Beek2021-08-311-0/+2
| | | | | | | | Match `int.is_integer`, which was added in python/cpython#6121
| * TST: Add tests for `np.floating.is_integer`Bas van Beek2021-08-311-1/+0
| |
* | TST: Update the IO-related typing testsBas van Beek2021-09-022-3/+22
| |
* | STY: Use the PEP 457 positional-only syntax in `numpy.typing`Bas van Beek2021-08-312-100/+102
|/
* BLD: Drop typing extension as an (optional) runtime dependencyBas van Beek2021-08-302-42/+0
| | | | It might return in the future, but as of the moment we don't need it anymore
* MAINT: Drop .pyi code-paths specific to Python 3.7Bas van Beek2021-08-302-4/+3
|
* MAINT: Drop .py code-paths specific to Python 3.7Bas van Beek2021-08-307-570/+417
|
* Merge pull request #19680 from BvB93/fromregexCharles Harris2021-08-162-1/+1
|\ | | | | ENH: Allow `np.fromregex` to accept `os.PathLike` implementations
| * ENH: Allow `np.fromregex` to accept `os.PathLike` implementationsBas van Beek2021-08-162-1/+1
| |
* | TST: Add typing tests for `np.lib.stride_tricks`Bas van Beek2021-08-162-0/+37
|/
* TST: Add typing tests for `np.lib.npyio`Bas van Beek2021-08-133-1/+102
|
* Merge pull request #19540 from BvB93/getlimitsCharles Harris2021-07-271-0/+4
|\ | | | | MAINT: Update the `np.finfo` annotations
| * MAINT: Update the `np.finfo` annotationsBas van Beek2021-07-221-0/+4
| | | | | | | | Reflect the `finfo` changes, made in https://github.com/numpy/numpy/pull/18536, in the classes' type annotations.
* | Merge pull request #19554 from MatthieuDartiailh/nditer-typingMatti Picus2021-07-271-0/+19
|\ \ | | | | | | MAINT: add missing dunder method to nditer type hints
| * | first pass at adding nditer typing testsMatthieu Dartiailh2021-07-271-0/+19
| | |
* | | Merge pull request #19559 from BvB93/pytestMatti Picus2021-07-262-0/+3
|\ \ \ | |/ / |/| | ENH: Add annotations for `__path__` and `PytestTester`
| * | ENH: Add `__path__` annotations to all sub-packagesBas van Beek2021-07-251-0/+1
| | |
| * | ENH: Add annotations for `<module>.test` objectsBas van Beek2021-07-251-0/+2
| | |
* | | TST: Update the `np.core.numerictypes` typing testsBas van Beek2021-07-222-12/+18
| |/ |/|
* | Merge pull request #19525 from BvB93/optionalSebastian Berg2021-07-211-0/+35
|\ \ | | | | | | TST: Test that `numpy.typing` can be imported in the absence of typing-extensions
| * | TST: Remodel the typing-extensions test after `test_full_reimport`Bas van Beek2021-07-211-38/+17
| | | | | | | | | | | | Co-Authored-By: Sebastian Berg <sebastian@sipsolutions.net>
| * | TST: Test that `numpy.typing` can be imported in the the absence of ↵Bas van Beek2021-07-191-0/+56
| | | | | | | | | | | | typing-extensions
* | | ENH: Add the `axis` and `ndim` attributes to `np.AxisError` (#19459)Bas van Beek2021-07-203-8/+6
|/ / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This PR adds the new axis and ndim attributes to the np.AxisError class, an addition inspired by similar changes introduced to AttributeError in Python 3.10. It also provided an excuse to update the classes' documentation and tests, both of which were previously rather lacking. * ENH: Add the `axis` and `ndim` attributes to `np.AxisError` * MAINT: Let the new `AxisError` attributes survive pickling * DOC: Update the `AxisError` documentation * TST: Update the `AxisError` tests * DOC: Add a release note * MAINT: Improve the description of `AxisError`s overloaded constructor * TST: Fix a few typing test failures * DOC: Clarify a fix a few parts of the `AxisError` docstrings Co-Authored-By: Eric Wieser <425260+eric-wieser@users.noreply.github.com> * DOC: Reguide fix * DOC: Replace `versionadded` with `versionchanged` Co-authored-by: Eric Wieser <wieser.eric@gmail.com> * DOC: Mention that `AxisError` is a `ValueError` and `IndexError` subclass Co-Authored-By: Sebastian Berg <sebastian@sipsolutions.net> * ENH: Delay assembling of the error message until `__str__` is called Co-Authored-By: Eric Wieser <425260+eric-wieser@users.noreply.github.com> * DOC: Update the `AxisError` string representation in its docstring * DOC: Update `versionadded`-related information Co-Authored-By: Eric Wieser <425260+eric-wieser@users.noreply.github.com> * DOC: Fix sphinx warnings Co-authored-by: Eric Wieser <425260+eric-wieser@users.noreply.github.com> Co-authored-by: Eric Wieser <wieser.eric@gmail.com> Co-authored-by: Sebastian Berg <sebastian@sipsolutions.net>
* | Merge pull request #19444 from BvB93/shape_baseCharles Harris2021-07-192-5/+66
|\ \ | | | | | | ENH: Add annotations for `np.lib.shape_base`
| * | TST: Add typing tests for `__array_prepare__` and `__array_wrap__`Bas van Beek2021-07-091-5/+9
| | |
| * | TST: Add typing tests for `np.lib.shape_base`Bas van Beek2021-07-091-0/+57
| |/
* | Merge pull request #19421 from BvB93/getlimitsCharles Harris2021-07-191-0/+69
|\ \ | | | | | | ENH: Add annotations for `np.core.getlimits`
| * | TST: Add typing tests for `np.core.getlimits`Bas van Beek2021-07-091-0/+69
| |/
* | TST: Update the `dtype` typing testsBas van Beek2021-07-132-2/+10
| |
* | TST: Fix a `GenericAlias` test failure for python 3.9.0Bas van Beek2021-07-121-1/+8
|/
* MAINT: Remove unused imports and unreachable code (#18762)Elisha Hollander2021-07-071-3/+0
| | | * Remove unnecessary imports and minor fixes
* TST: Update the typing testsBas van Beek2021-06-272-19/+19
|
* TST: Update the typing tests for `np.number` subclassesBas van Beek2021-06-252-0/+42
|
* Merge pull request #19295 from BvB93/typing-docsCharles Harris2021-06-243-26/+44
|\ | | | | DOC: Add `versionadded` directives to `numpy.typing`
| * DOC: Minor rewordingBas van Beek2021-06-251-1/+1
| |
| * DOC: Move the `versionadded` directive to the bottom of the bullet pointBas van Beek2021-06-221-3/+4
| | | | | | | | Co-Authored-By: Charles Harris <charlesr.harris@gmail.com>
| * DOC: Add `versionadded` directives to `numpy.typing`Bas van Beek2021-06-223-3/+15
| |
| * DOC: Move the `mypy`-plugin docs to its respective moduleBas van Beek2021-06-222-27/+32
| |
* | TST: Test that the `numpy.typing` public API works in combination with ↵Bas van Beek2021-06-241-0/+90
| | | | | | | | | | | | | | | | runtime Introspection helpers * `typing.get_type_hints` * `typing.get_args` * `typing.get_origin`
* | MAINT: Replace `"dtype[Any]"` with `dtype` in the definiton of `npt.ArrayLike`Bas van Beek2021-06-241-1/+1
| | | | | | | | | | | | Strings and types that are not subscriptable during runtime can cause issues with runtime Introspection helpers such as `typing.get_type_hints`. While this is very much an upstream issue, the particular case of `npt.ArrayLike` can be quite easily resolved in numpy.
* | Merge pull request #19135 from ganesh-k13/BUG_13236_remove_complex_floor_divideCharles Harris2021-06-232-46/+0
|\ \ | | | | | | BUG: Remove complex floor divide
| * | BUG, TST: Removed complex floor division cases in typing:revealGanesh Kathiresan2021-05-301-24/+0
| | |
| * | BUG, TST: Removed complex floor division cases in typing:passGanesh Kathiresan2021-05-301-22/+0
| | |