1
0
forked from VimPlug/jedi
Commit Graph

61 Commits

Author SHA1 Message Date
Dave Halter f1ab9d9539 Remove some 3.8 artifacts 2026-04-27 14:41:58 +02:00
Dave Halter 1eddf24a50 Remove Python 3.9 and 3.10 2026-04-27 00:34:17 +02:00
Dave Halter 8cbb817b12 Fix a lot of test related typing issues 2026-02-10 19:38:55 +01:00
Eric Masseran 4ea7981680 Add complete test 2025-08-29 18:37:51 +02:00
Eric Masseran d53a8ef81c Support init customization on dataclass_transform source 2025-05-05 02:02:17 +02:00
Eric Masseran eb80dc08f3 Add decorator tests - sandwich mode 2025-05-05 00:37:38 +02:00
Eric Masseran e49032ed6b Dataclass transform typing extension without Final support 2025-03-18 00:59:27 +01:00
Eric Masseran e20c3c955f Dataclass 3.7 mode without Final 2025-03-18 00:52:01 +01:00
Eric Masseran a3fd90d734 Fix dataclass decorator other parameters 2025-03-18 00:42:58 +01:00
Eric Masseran 999332ef77 Dataclass transform change init False 2025-03-18 00:30:50 +01:00
Eric Masseran e140523211 Fix attrs + remove dataclass_transform init=false tests 2025-03-17 23:51:53 +01:00
Eric Masseran bd1edfce78 Fix test 2025-03-17 19:48:42 +01:00
Eric Masseran 7dcb944b05 Fix decorator transformed case 2025-03-15 16:42:16 +01:00
Eric Masseran 50778c390f Fix init=false for transform and exclude fields on base transform 2025-03-15 16:23:32 +01:00
Eric Masseran e0797be681 Check final+classvar support for dataclass transform 2025-03-15 16:02:23 +01:00
Eric Masseran 8912a35502 Support init=False for dataclass_transform 2025-03-15 16:00:51 +01:00
Eric Masseran 77cf382a1b Support init=False for dataclass 2025-03-15 15:53:51 +01:00
Eric Masseran 70efe2134c Check final support for dataclass 2025-03-15 13:17:18 +01:00
Eric Masseran 472ee75e3c Add ClassVar support for dataclass 2025-03-15 13:15:19 +01:00
Eric Masseran 68c7bf35ce Add init cases for dataclass 2025-03-15 13:07:35 +01:00
Eric Masseran 027e29ec50 Support base class and metaclass mode 2025-02-15 20:12:53 +01:00
Eric Masseran d866ec0f80 Add support for dataclass_transform decorator 2025-02-14 17:05:28 +01:00
Peter Law 68e435cc66 Update 'next' signature in Python 3.13 where it's been fixed 2024-07-02 21:37:34 +01:00
Peter Law 57e7b83455 Add missing import
I suspect this got lost in a merge somewhere, probably the
combination of 7e533ca7e1 and the
Python 3.12 work in a60fdba1d4.
2023-09-22 21:29:31 +01:00
Dave Halter 0770372857 Merge pull request #1956 from PeterJCLaw/python-3.12
Support Python 3.12
2023-09-17 19:25:45 +00:00
Peter Law 7e533ca7e1 Drop redundant conditional skips for unsupported Python versions 2023-09-17 18:38:12 +01:00
Peter Law a60fdba1d4 Adjust for change to documention change of next in Python 3.12
The signature of the builtin isn't actually changing in Python 3.12,
however its documentation has changed.
2023-09-17 18:27:53 +01:00
Peter Law 3dbcd2c6de Whitespace 2023-05-27 00:10:00 +01:00
Alex Ford 4d1e00c3ab Skip if attrs not in target environment.
Add check for attrs in test environment and skip if not installed.
This is patterned off the existing django tests.
2022-10-13 00:43:29 -07:00
Alex Ford e15f51ecc1 Remove mutable from attrs signature tests 2022-10-11 17:55:57 -07:00
Alex Ford 40e1e3f560 Extend dataclass constructor hinting to attrs next-gen apis.
Trivially extends dataclass constructor hinting to attrs next-gen APIs.

This will stumble in cases where attrs extends beyond the standard
dataclasses API, such as complex use of defaults, converters, et al.
However, it likely covers the vast majority of cases which fall solidly
in the intersection of the two APIs.

Extension beyond these cases could use [PEP0681 dataclass_transforms],
however this is definitely a problem for another day.

[PEP0681 dataclass_transforms]: https://peps.python.org/pep-0681/

https://github.com/davidhalter/jedi/issues/1835
2022-10-11 17:40:31 -07:00
Peter Law 6787719c28 Ensure *args, **kwargs lookthrough works at module scope too
This means that passthrough signatures will be found for top level
functions, which is useful both where they're wrappered by
`functools.wraps` or not.

Fixes https://github.com/davidhalter/jedi/issues/1791.
2021-07-24 16:58:34 +01:00
Peter Law bb40390225 Add identifiers to these test strings
This makes it easier to work out which one fails when pytest
reports a failure. Mostly useful when introducing failing tests,
which I'm about to do.
2021-07-24 16:15:41 +01:00
Peter Law 0d15347210 Remove confusing comment
I'm assuming that this is incorrect given that there _are_ arguments
where the comment suggests there aren't any.
2021-07-24 16:14:20 +01:00
Dave Halter 85f45771f1 Fix typing.NewType signature 2021-01-01 04:22:52 +01:00
Dave Halter 30e702de11 Generics don't have signatures 2021-01-01 04:09:49 +01:00
Dave Halter 778442a972 Type aliases should not have a signature 2021-01-01 03:59:28 +01:00
Dave Halter 4f34712858 Fix signatures for TypeVar and cast, fixes #1709 2021-01-01 03:59:12 +01:00
Dave Halter d821451a64 Upgrade typeshed 2021-01-01 03:18:49 +01:00
Dave Halter 5d2aed34f4 Fix signatures if a decorator has no signatures, fixes #1705 2020-12-28 00:47:10 +01:00
Dave Halter e671a0cb6d Fix an error with enums, fixes #1675 2020-10-23 20:25:00 +02:00
Dave Halter 7e295d05a1 Remove some more Python 2/3.5 references 2020-07-02 00:25:00 +02:00
Dave Halter 50b85153ce Remove a lot of test references to Python 2/3.5 2020-07-02 00:17:21 +02:00
Dave Halter 0888dd468f Fix partialmethod issues 2020-03-14 01:22:46 +01:00
Daniel Lemm fd6540a9e5 Fix PartialMethodObject (WIP)
Implemented feedback from PR #1522.
Does not pass new tests in test/completion/stdlib.py
2020-03-13 21:40:58 +01:00
Daniel Lemm 96c969687a Add partialmethod, fixes #1519
Returns correct method signature but test/completion/stdlib.py fails
2020-03-12 18:47:17 +01:00
Dave Halter 8cc836e816 find_signatures -> get_signatures, see #1476 2020-01-22 01:10:38 +01:00
Dave Halter 9c4cd40b7e Fix signatures when used for Generic classes, fixes #1468 2020-01-06 09:40:57 +01:00
Dave Halter 74fc29be9a Make sure that kwargs are not repeated when they are inferred 2020-01-05 01:48:10 +01:00
Dave Halter 8e2bfdc07e Add a test for #1465 2020-01-01 14:03:42 +01:00