Message345147
This is a regression from python2.x behaviour:
$ python2
Python 2.7.15rc1 (default, Nov 12 2018, 14:31:15)
[GCC 7.3.0] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> x = set()
>>> x.difference(123)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
TypeError: 'int' object is not iterable
$ python3.8
Python 3.8.0b1 (default, Jun 6 2019, 03:44:52)
[GCC 7.4.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> x = set()
>>> x.difference(123)
set()
The regression appears to be introduced in this patch: 4103e4dfbce
https://github.com/python/cpython/commit/4103e4dfbce |
|
Date |
User |
Action |
Args |
2019-06-10 22:01:36 | Anthony Sottile | set | recipients:
+ Anthony Sottile, rhettinger |
2019-06-10 22:01:36 | Anthony Sottile | set | messageid: <1560204096.52.0.24651391919.issue37219@roundup.psfhosted.org> |
2019-06-10 22:01:36 | Anthony Sottile | link | issue37219 messages |
2019-06-10 22:01:36 | Anthony Sottile | create | |
|