Closed Josverl closed 2 years ago
@jakobrosenberg , after testing it appears that this is caused by PyLance : https://github.com/microsoft/pylance-release/issues/2978
the good news is that devices with rootPath = \flash
or \sd
could have much less impact (as long as the local filesystem does not have that folder.
however in the current logic you seem to remove/hide the \flash
part in the logic and expose /
as the root of the virtual device
depending how quick Pylance resolve this it may actually be good to expose the actual location \flash\foo.py
in the virtual filesystem
I have considered exposing the full path, but the gains vs unforeseen implications make it a low priority. Is it correct that this is not a bug of Pymakr but an issue between VSCode and Pylance?
Indeed I can repro outside of Pymakr , and Pylance flagged this as a BUG to be resolved by them
Closing as not currently planned, but I'd love a discussion on whether we should expose the full path in the file provider. This is something I couldn't decide on when the feature was added and it almost came down to a coin flip.
pymakr open in device explorer stops pylance from working when a MCU is attached and the rootpath of the device is
/
(likely is similar but much smaller problem is also found for devices with
/flash
rootpath ) this was reported in : https://github.com/Josverl/micropython-stubs/issues/580 please refer to this for additional infoTo Reproduce See : https://github.com/Josverl/stubs-esp-test/blob/main/repro.md
Expected behavior Pylance to work as expected when a MCU is mounted in the explorer view
Desktop :