Closed rivaros closed 9 months ago
Hey @rivaros , are you using workspace in vscode for your project? I think I have seen this error in another issue, it should be related to new feature we added.
Also, please try to uninstall extension and delete extension folder from /Users/XXX/.vscode/extensions/
, and install it again to see if it can be resolved.
@EzioLi01 Deleting extension folder has no effect. On fresh install it spits the error again. And yes, am using workspace.
It looks schematically like this
{
"folders": [
{
"name": "lib",
"path": "<path to some lib>"
},
{
"path": "mobile"
},
{
"path": "mobile-ci"
},
{
"path": "mobile-web"
}
]
}
mobile
folder contains react native project. As I said, prod version of extension works good.
@EzioLi01 Yes, when I use "Open Folder..." to directly open the react native project it works. But still it's pretty much unusable without workspaces, because usually when working on a project you also have backend and ci stuff which resides in different folders.
Also getting the following error
Failed to fetch source map http://x.x.x.x:8081/index.map?platform=ios&dev=true&minify=false&inlineSourceMap=false&modulesOnly=false&runModule=true&app=com.app.name: remote fetches not permitted
It kinda works even with this error. Should I be concerned about it as well?
If this error is not blocking your debugging, I think we can ignore it so far.
For the error, it's related to a new feature that is not available on prod version.
Is it possible to provide your whole workspace settings file .code-workspace
for the investigation? It may have format issue in JSON file, I think.
@EzioLi01 probably you are parsing.code-workspace
with JSON.parse. It is JSONP file, which can have comments.
https://code.visualstudio.com/docs/editor/multi-root-workspaces#_workspace-file-schema
Could it be that it's failing because of comments in workspace file?
@EzioLi01 probably you are parsing
.code-workspace
with JSON.parse. It is JSONP file, which can have comments.https://code.visualstudio.com/docs/editor/multi-root-workspaces#_workspace-file-schema
Could it be that it's failing because of comments in workspace file?
Nice catch! I think this should be the root cause, I have missed it in feature. Will do fixing for it with priority, any updates will comment here. Appreciating this great issue!
Hey @rivaros , could you please install and try on this .vsix
file to see if it's resolved?
Please uninstall existing extension and delete react-native-tools folder from /.vscode/extensions
to prevent any conflict. Thank you!
Any issue please let me know.
Hi @EzioLi01 ,
Concerning VSIX - it works good with my project now 👍 Many thx. There is still a minor issue - it crashes on trailing commas, but this is well - edge case.
Hi @EzioLi01 ,
Concerning VSIX - it works good with my project now 👍 Many thx. There is still a minor issue - it crashes on trailing commas, but this is well - edge case.
Thanks @rivaros for the confirm, please using this for debugging. I will send PR for the fixing, once PR merged, it will be available on nightly version.
I will try to improve comma issue as well, maybe add stripJsonTrailingComma
function or add some useful message for it.
🐛 What is the bug? How can we reproduce it?
Getting the following error in "React Native" output. Looks like extension fails to initialize on the project
[Error] Failed to activate the React Native Tools extension (error code 702)
Important: Stable version
v1.12.1
works goodAnother syndrom:
When trying to attach/debuggetting error:
Launch.json seems ok:
Environment
Please tell us about your system and your project:
npx react-native doctor
ornpx expo doctor
if your project is using Expo:envinfo
: