microsoft / devicescript

TypeScript for Tiny IoT Devices (ESP32, RP2040, ...)
https://microsoft.github.io/devicescript/
MIT License
3.28k stars 118 forks source link

Error in simulator after fresh setup #405

Closed jurosh closed 1 year ago

jurosh commented 1 year ago

After fresh install and new project creation, it's not possible to run Simulator.

Error:

DeviceScript - Install Node.JS dependencies to enable tools.

Environment:

Linux
NodeJs v18.12.1
Yarn 3.3.0
jurosh commented 1 year ago

Looks like there is no support for Yarn (other than v1). It's probably needed to add .yarnrc.yml with:

nodeLinker: node-modules
pelikhan commented 1 year ago

We are still using yarn v1, are you saying .yarnrc.yml should be added to the generated files? thanks for reporting!

jurosh commented 1 year ago

If I understand correctly how init.ts works, this might fix it... PR: https://github.com/microsoft/devicescript/pull/406

It will enforce Yarn v2, v3, .. to use node_modules instead of Plug & Play modules..

pelikhan commented 1 year ago

In 2.9.13. Thanks!