Closed JeffHanna closed 5 years ago
Related #1242.
What language server version are you on? Are you running a daily/beta build?
@CTrando #1254 should have only shown this message if both sides were known builtin types, but pathlib stuff doesn't count, so the message shouldn't have been shown...
Is the language server a different version # than the Python Extension version #? If so, please provide information on how to retrieve it. The Python Extension I'm on, as stated above, is 2019.6.24.221
It is. You can find it in the output panel with Python selected.
https://github.com/microsoft/python-language-server/blob/master/TROUBLESHOOTING.md#filing-an-issue
PLS version # is 0.3.22.0
For now, you can disable this message with:
"python.analysis.disabled": ["unsupported-operand-type"]
Environment data
"python.jediEnabled"
set to; more info #3977): Jedi == FalseExpected behaviour
Statements such as: FILEPATH_SETTINGS = pathlib.Path.home( ) / 'AppData' / 'Local' / 'ZeeWise Assistant' / 'settings.json' Should not generate errors that the / character is an unsupported operand type for str and str.
Actual behaviour
False positive linting errors are generated that claim the / character is an unsupported operand type for str and str. / is the proper path separation delimiter character to use to concatenate path parts in pathlib.
This error only started with the 2019.6.24221 update to the Python Language Server. Older versions handled pathlib delimiters without generating linting errors.
Steps to reproduce:
Logs
Output for
Python
in theOutput
panel (View
→Output
, change the drop-down the upper-right of theOutput
panel toPython
)Output from
Console
under theDeveloper Tools
panel (toggle Developer Tools on underHelp
; turn on source maps to make any tracebacks be useful by runningEnable source map support for extension debugging
)