Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Failed to parse JSON file ~/.proto/tools/node/manifest.json when running multiple tasks #85

Closed
konomae opened this issue Apr 24, 2023 · 14 comments · Fixed by #87
Closed

Comments

@konomae
Copy link

konomae commented Apr 24, 2023

Occasionally the following errors may occur. 🤔
maybe, related: #75


My package.json:

{
  "name": "proto-problem",
  "version": "1.0.0",
  "scripts": {
    "task": "run-p task:*",
    "task:a": "node -e \"console.log('a')\"",
    "task:b": "node -e \"console.log('b')\"",
    "task:c": "node -e \"console.log('c')\"",
    "task:d": "node -e \"console.log('d')\"",
    "task:e": "node -e \"console.log('e')\"",
    "task:f": "node -e \"console.log('f')\"",
    "task:g": "node -e \"console.log('g')\"",
    "task:h": "node -e \"console.log('h')\"",
    "task:i": "node -e \"console.log('i')\"",
    "task:j": "node -e \"console.log('j')\""
  },
  "devDependencies": {
    "npm-run-all": "^4.1.5"
  }
}

and proto version 0.7.0:

proto --version
proto 0.7.0

then, run the task:

npm install
npm run task

and the result:

Error: proto::json
  × Failed to parse JSON file ~/.proto/tools/node/manifest.json
  ╰─▶ EOF while parsing a value at line 1 column 0
@milesj
Copy link
Contributor

milesj commented Apr 24, 2023

Can you try v0.7.1?

@konomae
Copy link
Author

konomae commented Apr 25, 2023

@milesj
It was fixed! 🎉
Thank you!

@milesj
Copy link
Contributor

milesj commented Apr 25, 2023

Awesome

@YishaqG
Copy link

YishaqG commented Sep 1, 2023

Getting the same error:

Error: json::parse_file

  × Failed to parse JSON file ~/.proto/tools/node/manifest.json.
  ╰─▶ EOF while parsing a value at line 2 column 0

Proto version: 0.15.1

@milesj
Copy link
Contributor

milesj commented Sep 2, 2023

@YishaqG What commands are you running to hit it?

@milesj milesj reopened this Sep 2, 2023
@YishaqG
Copy link

YishaqG commented Sep 2, 2023

@milesj Just running node or npm, was working with worker_threads module and after a couple of runs I got that error.

@milesj
Copy link
Contributor

milesj commented Sep 3, 2023

Just released 0.16, can you give that a shot?

If this still persists, I'll have to rewrite it, since I'm doing everything I already can with file locks.

@milesj
Copy link
Contributor

milesj commented Sep 13, 2023

Is this still an issue?

@YishaqG
Copy link

YishaqG commented Sep 13, 2023

Sorry for the late reply, I don't know if the version 0.16 would fix it. Found a workaround by erasing the .proto/tools/node/manifest.json and then re-setting the global node version. Hope this help, if don't, I could try to replicate the issue

@ImBIOS
Copy link
Contributor

ImBIOS commented Sep 26, 2023

I'm experiencing the same thing as @YishaqG
I'm in proto 0.18.2

@milesj
Copy link
Contributor

milesj commented Sep 26, 2023

Attempt here #216 Will patch soon.

@milesj
Copy link
Contributor

milesj commented Sep 26, 2023

Can you try 0.18.4. If it's still an issue, I have 1 more idea to fix it.

@ImBIOS
Copy link
Contributor

ImBIOS commented Sep 27, 2023

@milesj Thanks, 0.18.4 fixed it.

@milesj
Copy link
Contributor

milesj commented Sep 27, 2023

Cool. I'll leave this open just in case it's still happening

@milesj milesj closed this as completed Oct 20, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging a pull request may close this issue.

4 participants