Message302736
There's a bit of history I don't understand and couldn't find the appropriate trail for.
The original error message from the 2.6 era:
$ python2.6 -c 0[0]
Traceback (most recent call last):
File "<string>", line 1, in <module>
TypeError: 'int' object is unsubscriptable
This was changed in https://github.com/python/cpython/commit/f5fd5239819c5dfb1d7a33484be49dc705544d02 for clarity
As seen in 2.7.1
$ ./python2.7.1 -c 0[0]
Traceback (most recent call last):
File "<string>", line 1, in <module>
TypeError: 'int' object is not subscriptable
It was later changed in the 2.7 era here:
https://github.com/python/cpython/commit/7d1483cbadbe48620964348a2039690624e7dc8e
To this error message (as demonstrated with 2.7.12):
$ python2.7 -c 0[0]
Traceback (most recent call last):
File "<string>", line 1, in <module>
TypeError: 'int' object has no attribute '__getitem__'
However, this patch never made it into the 3.x branch:
$ python3.6 -c 0[0]
Traceback (most recent call last):
File "<string>", line 1, in <module>
TypeError: 'int' object is not subscriptable
Should this patch be (have been) cherry picked into master? |
|
Date |
User |
Action |
Args |
2017-09-22 03:32:38 | Anthony Sottile | set | recipients:
+ Anthony Sottile |
2017-09-22 03:32:38 | Anthony Sottile | set | messageid: <1506051158.28.0.318471298874.issue31550@psf.upfronthosting.co.za> |
2017-09-22 03:32:38 | Anthony Sottile | link | issue31550 messages |
2017-09-22 03:32:37 | Anthony Sottile | create | |
|