79287648

Date: 2024-12-17 11:16:21
Score: 0.5
Natty:
Report link

After extensive research, I noticed the following in the expo.cmd file that is generated in the app's node_modules directory:

@IF EXIST "%~dp0\node.exe" (
  "%~dp0\node.exe" "%~dp0\..\..\..\..\node_modules\expo\bin\cli" %*
) ELSE (
  @SETLOCAL
  @SET PATHEXT=%PATHEXT:;.JS;=;%
  node "%~dp0\..\..\..\..\node_modules\expo\bin\cli" %*
)

In the cases where it fails, both paths include an additional ..\:

\..\..\..\..\..\node_modules\expo\bin\cli

This makes sense to some extent because I added another subfolder in my workspace structure. However, due to the error message, I ended up manually modifying the .cmd file and removing the additional ... After doing this, it worked as expected.

Since Expo has limited support for workspaces, I assume this is an edge case that was simply never considered or tested. My explanation is still quite vague, though, and I would appreciate it if anyone here has deeper insights into why this happens or how it can be resolved more cleanly.

Reasons:
  • Blacklisted phrase (1.5): would appreciate
  • Whitelisted phrase (-1): it worked
  • Long answer (-0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (0.5):
Posted by: Marco D.