You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Open a Python project in VSCode that uses the PySide6 library
Hover over QObject or any other PySide6 class/function and press F12 to go to its definition
Try to go to the definition of another class/function by pressing F12 again
bug-report.mp4
Expected behavior
F12 should smoothly switch between different class/function definitions without freezing.
Actual behavior
After using F12 to go to a definition in PySide6 for the first time, subsequent uses of F12 cause Pylance to hang and become unresponsive for dozens of seconds. This also affects other VSCode functionalities such as creating new files.
When working in an SSH Remote environment, this issue also cause the SSH connection to drop. Remote system is Ubuntu 23.10, other softwares version is same to this issue.
For Python language, Blockman uses dt-python-parser, which is not exactly optimized for finding block start-end locations (tokens), it tokenizes everything in the Python code. And maybe it is the reason that it overanalyzes the file and causes freezing.
I will try to implement other libraries (more optimized, or more stable libraries) for parsing/tokenizing in Blockman.
It seems to be caused by the excessive length of the PySide6 pyi files.
Environment data
Code Snippet
Repro Steps
bug-report.mp4
Expected behavior
F12 should smoothly switch between different class/function definitions without freezing.
Actual behavior
Ubuntu 23.10
, other softwares version is same to this issue.Logs
Pylance log link: https://github.com/myuanz/pylance-pyside-hang/blob/master/test2.log
I'm not sure how to view the Blockman log, but there seem to be some traces in the Pylance log:
microsoft/pylance-release#5847 (comment)
The text was updated successfully, but these errors were encountered: