Created on 2017-11-16 09:09 by serhiy.storchaka, last changed 2018-08-02 23:52 by berker.peksag. This issue is now closed.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 4417 | merged | corona10, 2017-11-16 11:14 | |
| Messages (6) | |||
|---|---|---|---|
| msg306346 - (view) | Author: Serhiy Storchaka (serhiy.storchaka) * | Date: 2017-11-16 09:09 | |
Currently 2to3 converts `operator.isCallable(obj)` to `hasattr(obj, '__call__')`. This looks cumbersome, and can be deceived by instance attribute __call__. The more correct way is to use `isinstance(obj, collections.abc.Callable)`. Starting from Python 3.2 it can use the callable() builtin. |
|||
| msg306454 - (view) | Author: Guido van Rossum (gvanrossum) * | Date: 2017-11-17 19:27 | |
I would convert this to `callable()` -- the conversion to collections.abc.Callable is more verbose and requires an extra import (that can be slow). |
|||
| msg307142 - (view) | Author: Éric Araujo (eric.araujo) * | Date: 2017-11-28 16:27 | |
New changeset a489599793f9b00ddc2c68e2ce3bce9cbb2c09a2 by Éric Araujo (Dong-hee Na) in branch 'master': bpo-32046: Update 2to3 when converts operator.isCallable(obj). (#4417) https://github.com/python/cpython/commit/a489599793f9b00ddc2c68e2ce3bce9cbb2c09a2 |
|||
| msg307143 - (view) | Author: Éric Araujo (eric.araujo) * | Date: 2017-11-28 16:29 | |
Merged in master, I suppose stable branches should be left alone? |
|||
| msg321608 - (view) | Author: Dong-hee Na (corona10) * | Date: 2018-07-13 13:27 | |
@serhiy.storchaka If we don't have plans with backporting patches than we can close this issue. |
|||
| msg322998 - (view) | Author: Berker Peksag (berker.peksag) * | Date: 2018-08-02 23:52 | |
> I suppose stable branches should be left alone? We do backport lib2to3 PRs to maintenance branches, but since this is already in 3.7 and 3.6 is four months away from being in security-fix-only mode, I think we can close this as 'fixed' now. |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2018-08-02 23:52:19 | berker.peksag | set | status: open -> closed nosy:
+ berker.peksag resolution: fixed |
| 2018-07-13 15:13:43 | gvanrossum | set | nosy:
- gvanrossum |
| 2018-07-13 13:27:18 | corona10 | set | messages: + msg321608 |
| 2017-11-28 16:29:21 | eric.araujo | set | messages: + msg307143 |
| 2017-11-28 16:27:00 | eric.araujo | set | messages: + msg307142 |
| 2017-11-17 19:27:57 | gvanrossum | set | nosy:
+ gvanrossum messages: + msg306454 |
| 2017-11-16 18:26:02 | eric.araujo | set | messages: - msg306393 |
| 2017-11-16 18:25:43 | eric.araujo | set | nosy:
+ eric.araujo messages: + msg306393 |
| 2017-11-16 14:52:23 | corona10 | set | nosy:
+ corona10 |
| 2017-11-16 11:14:20 | corona10 | set | keywords:
+ patch stage: patch review pull_requests: + pull_request4366 |
| 2017-11-16 09:09:32 | serhiy.storchaka | create | |