PythonScript
PythonScript copied to clipboard
[2.0]TypeError: 'tuple' object is not callable when using range
I'm using Emmet, it's working but not updated for a long time and broken with Pythonscript 3.0.13-alpha so I have to using 2.0
But I got problem with 2.0 version, every code with range throw an error so emmet is working with Python 2.0 but my user script is broken
Any help?
a=range(3)
Traceback (most recent call last):
File "<console>", line 1, in <module>
TypeError: 'tuple' object is not callable
for i in range(3):
print(i);
TypeError: 'tuple' object is not callable
p.s. notepad++ 8.3.3 x64
This is a valid code and PS 2.0 can use it without any problems.

So either emmet is doing something here, or your code is messing up the built-in range function.
This is a valid code and PS 2.0 can use it without any problems.
https://user-images.githubusercontent.com/47723516/164424469-d56e3bf0-9492-4a8e-b355-cb04063469ed.png
So either emmet is doing something here, or your code is messing up the built-in range function.
Lol thanks you're right, I found that my other ancient code snippet wrote something like range = editor.getUserCharSelection()
@byzod - would you mind closing this issue or is there something left to discuss/fix?