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

Error: EAGAIN during readSync #208

Closed
noahseger opened this issue Nov 16, 2022 · 10 comments
Closed

Error: EAGAIN during readSync #208

noahseger opened this issue Nov 16, 2022 · 10 comments

Comments

@noahseger
Copy link

Similar to #7, we've seen stdin fail as the number of protobufs we're processing has increased:

buf generate
node:fs:738
  handleErrorFromBinding(ctx);
  ^

Error: EAGAIN: resource temporarily unavailable, read
    at Object.readSync (node:fs:738:3)
    at tryReadSync (node:fs:438:20)
    at readFileSync (node:fs:484:19)
    at file:///runner/_work/definitions/definitions/node_modules/twirpscript/compiler.js:4:15
    at ModuleJob.run (node:internal/modules/esm/module_job:193:25)
    at async Promise.all (index 0)
    at async ESMLoader.import (node:internal/modules/esm/loader:526:24)
    at async loadESM (node:internal/process/esm_loader:91:5)
    at async handleMainPromise (node:internal/modules/run_main:65:12) {
  errno: -11,
  syscall: 'read',
  code: 'EAGAIN'
}
Failure: plugin protoc-gen-twirpscript: exit status 1

Running under Node 16 in GitHub Actions:

      - uses: actions/setup-node@v3
        with:
          node-version: 16

All I've found so far is https://stackoverflow.com/questions/40362369/stdin-read-fails-on-some-input, and I don't know if you have the flexibility to read synchronously from /dev/stdin for portability.

@tatethurston
Copy link
Owner

Hey @noahseger, thanks for reporting. What version of twirpscript are you running?

@tatethurston
Copy link
Owner

I think I may have found a lead here: nodejs/help#2663. I'll put out a release switching to process.stdin usage. Once I release that, if you could let me know if the issue stops or if you continue to see it, I'd really appreciate it.

@noahseger
Copy link
Author

Hi @tatethurston , thanks for checking it out! We're running 0.0.61, and can definitely let you know whether or not it stops after that lands. This framework is the best 🤘

@tatethurston
Copy link
Owner

Awesome thanks Noah, I’ll let you know when I publish

@tatethurston
Copy link
Owner

This is fixed in 0.0.66. LMK if you run into any issues!

@noahseger
Copy link
Author

Thanks @tatethurston! This passed our CI so we'll land it and watch for the error over the next week 🎉

@tatethurston
Copy link
Owner

Thanks @noahseger!

@tatethurston
Copy link
Owner

@noahseger how has the incidence of this error looked after 0.0.66?

@noahseger
Copy link
Author

noahseger commented Dec 7, 2022 via email

@tatethurston
Copy link
Owner

tatethurston commented Dec 7, 2022

Awesome, thanks Noah

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants