python-lsp / python-lsp-server

Fork of the python-language-server project, maintained by the Spyder IDE team and the community
MIT License
1.76k stars 186 forks source link

Fix null reference for syntax errors due to invalid encodings (Pyflakes) #433

Closed smacke closed 10 months ago

smacke commented 10 months ago

If the syntax error is due to an invalid encoding, text will be None, so we give it an empty string in this case. This fixes https://github.com/python-lsp/python-lsp-server/issues/429.

Fixes #429.