DiamondLightSource / python3-pip-skeleton

Archived in favour of https://github.com/DiamondLightSource/python-copier-template
Apache License 2.0
4 stars 4 forks source link

Pylance not compatible with default editable installs in setuptools>64 #84

Open coretl opened 1 year ago

coretl commented 1 year ago

https://github.com/microsoft/pyright/blob/main/docs/import-resolution.md#editable-installs

We should do pip install -e . --config-settings editable_mode=compat in the dev container

coretl commented 1 year ago

Strict mode appears to be the future, but it creates a directory of softlinks. This means that clicking through takes you to a soft link, not the file itself, which is annoying. You also need to then set the breakpoint on the link not the original. Workarounds exist:

https://github.com/microsoft/debugpy/issues/1152#issuecomment-1349179183

However I think we should use compat mode for as long as it works...