summaryrefslogtreecommitdiff
path: root/astroid/brain
Commit message (Collapse)AuthorAgeFilesLines
* Remove old future import that are no longer requiredPierre Sassoulas2021-02-171-1/+0
|
* Use set litteral when possiblePierre Sassoulas2021-02-171-2/+2
|
* Move from % syntax to format or f-stringsPierre Sassoulas2021-02-173-8/+6
| | | | This is possible with python 3.6
* Remove the # coding, since PEP3120 the default is UTF8Pierre Sassoulas2021-02-177-7/+0
|
* Update copyright noticehippo912021-02-1525-8/+31
|
* The node.bases has not to be tweaked otherwise leads to false positive ↵hippo912021-02-121-1/+0
| | | | unused-import due to the fact that six.with_metaclass is not consumed. Adds a unittest to check that bases attribute holds a call node and that ancestors attributes returns the correct class hierarchy.
* Merge branch 'master' into masterhippo912021-02-076-0/+122
|\
| * Add support of 'six.with_metaclass' (#841)Francis Charette Migneault2021-02-071-0/+39
| | | | | | Closes #713
| * Julien palard mdk/class getitem (#885)hippo912021-01-241-0/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Add missing __class_getitem__ to deque. * The __class_getitem__ method is added only for python versions above 3.9 * Adds two tests that ensure that __class_getitem__ method is not present for python versions prior to 3.9 but present for python versions above 3.9 * Reorganizes * Adds an entry * Add Julien Palard in copyright Co-authored-by: Julien Palard <julien@palard.fr>
| * Merge branch 'sum_and_multiply' of https://github.com/hippo91/astroidsum_and_multiplyhippo912021-01-231-0/+2
| |\
| | * Merge branch 'master' into sum_and_multiplyhippo912020-06-2033-55/+235
| | |\
| | * \ Merge branch 'master' into sum_and_multiplyhippo912019-12-301-0/+6
| | |\ \
| | * | | Adds two missing ufunc instances (add and multiply)hippo912019-12-281-0/+2
| | | | |
| * | | | Merge pull request #883 from hippo91/bug_pylint_4001hippo912021-01-231-0/+64
| |\ \ \ \ | | | | | | | | | | | | Bug pylint 4001
| | * | | | Corrects a comment concerning node type as suggested by @PIerre-Sassoulashippo912021-01-231-1/+1
| | | | | |
| | * | | | Defines PY39 variablehippo912021-01-201-1/+4
| | | | | |
| | * | | | Formatting according to blackhippo912021-01-201-8/+2
| | | | | |
| | * | | | Adds dochippo912021-01-191-9/+36
| | | | | |
| | * | | | Deletes unused importhippo912021-01-191-3/+0
| | | | | |
| | * | | | Adds a brain to mock the __class_getitem__ method on the `type` class (only ↵hippo912021-01-181-0/+43
| | | | | | | | | | | | | | | | | | | | | | | | with python3.9)
| * | | | | brain: Add `__class_getitem__` to `subprocess.Popen` starting from Python 3.9Damien Baty2021-01-181-0/+7
| |/ / / / | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This is necessary for pylint to detect that `subprocess.Popen` is subscriptable, starting from Python 3.9 (see PyCQA/pylint#4034). $ python3.9 >>> import subprocess >>> subprocess.Popen.__class_getitem__ <bound method GenericAlias of <class 'subprocess.Popen'>>
| * | | | Fix a crash in inference caused by `Uninferable` container elementsClaudiu Popa2021-01-011-0/+2
| | | | | | | | | | | | | | | | | | | | Close #866
* | | | | Remove six from astroidDavid Gilman2020-12-303-18/+5
|/ / / /
* | | | Formatting according to blackhippo912020-12-291-2/+2
| | | |
* | | | Adds a note dealing with numpy version 1.18 and the __getattr__ methodhippo912020-12-291-1/+2
| | | |
* | | | Add the function random that is an alias of random_samplehippo912020-12-291-0/+1
| | | |
* | | | Adds the ufunc degrees and radianshippo912020-12-291-0/+2
| | | |
* | | | New copyright noticeshippo912020-12-2729-18/+33
| | | |
* | | | Fix a crash in functools.partial inference when the arguments cannot be ↵Claudiu Popa2020-12-271-5/+8
| | | | | | | | | | | | | | | | | | | | | | | | determined Close PyCQA/pylint#3776
* | | | Do not crash when encountering starred assignments in enums.Claudiu Popa2020-12-261-1/+2
| | | | | | | | | | | | | | | | Close #835
* | | | Formatting according to blackhippo912020-11-221-2/+3
| | | |
* | | | Takes into account the fact that in python3.9 NamedTuple in typing module is ↵hippo912020-11-221-0/+19
| | | | | | | | | | | | | | | | no more a class but a function.
* | | | Adds ndarray as rtype for T attribute.hippo912020-09-142-2/+2
| | | | | | | | | | | | Closes PyCQA/pylint#3387
* | | | Teach astroid about Hypothesis (#820)Zac Hatfield-Dodds2020-09-141-0/+53
| | | |
* | | | Add the value parameter in the signature of the __or__ method of the ndarray ↵hippo912020-09-141-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | class.
* | | | Fix warning regarding ABC import from collections (#825)Karthikeyan Singaravelan2020-09-141-2/+2
| | | |
* | | | Add comments and changelog entry (#830)hippo912020-09-142-2/+6
| | | |
* | | | Squash one-off inference utility functions to help reduce recursion errors ↵Bryce Guinta2020-06-231-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | (#804) This also makes debugging a lot simpler reducing the complexity of the function stack.
* | | | Separate string and bytes classes patching (#807)Claudiu Popa2020-06-231-47/+85
| | | | | | | | | | | | Fixes PyCQA/pylint#3599
* | | | Fix exception causes all over the codebase (#806)Ram Rachum2020-06-204-32/+32
| |_|/ |/| |
* | | brain_mechanize: Add missing methods to transform (#794)Peter Kolbus2020-05-281-1/+58
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The brain transform for mechanize was missing most methods for the Browser class, leading to false positives in pylint, such as: E1101: Instance of 'Browser' has no 'select_form' member (no-member) E1137: 'browser' does not support item assignment (unsupported-assignment-operation) Add missing methods to align with mechanize 0.4.5. Fixes #793. Co-authored-by: Claudiu Popa <pcmanticore@gmail.com>
* | | Add more supported parameters to ``subprocess.check_output()``.Peter Pentchev2020-05-281-0/+10
| | |
* | | Cleanup formatting errorsClaudiu Popa2020-05-141-3/+7
| | |
* | | Add brain for sqlalchemy.orm.sessionStefan Scherfke2020-05-121-0/+31
| | |
* | | Do not crash with SyntaxError when parsing namedtuples with invalid labelClaudiu Popa2020-05-011-0/+2
| | | | | | | | | | | | Close PyCQA/pylint#3549
* | | Add missing copyright annotations for the past releasesClaudiu Popa2020-04-2730-34/+55
| | |
* | | Transform read_module() into a lambda to prevent it being marked as a bound ↵Claudiu Popa2020-04-271-1/+1
| | | | | | | | | | | | method
* | | Export `six.moves.reload_module` from `importlib` not `imp`Claudiu Popa2020-04-271-1/+2
| | | | | | | | | | | | Close PyCQA/pylint#3509
* | | Add a new EvaluatedObject containerClaudiu Popa2020-03-101-3/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | This container is used to store values that have already been evaluated. For instance, 79d5a3a783cf0b5a729e4e467508e955a0cca55f added support for inferring `tuple()` call arguments, but as a result, the `elts` of a `Tuple` can be objects not *references*. As a result, `Tuple.elts` can contain class objects rather than references (names) to class object. The `EvaluatedObject` helps with that, as we still have to call `.infer()` (albeit a no-op) to grab the inferred value of an element.
* | | ``NodeNG.bool_value()`` gained an optional ``context`` parameterClaudiu Popa2020-03-051-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | We need to pass an inference context downstream when inferring the boolean value of a node in order to prevent recursion errors and double inference. This fix prevents a recursion error with dask library. Close PyCQA/pylint#2985