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鈥檒l occasionally send you account related emails.

Already on GitHub? Sign in to your account

Build freezes and ends with [Error: Bad file descriptor] #6840

Closed
Yash-Singh1 opened this issue Aug 31, 2021 · 4 comments
Closed

Build freezes and ends with [Error: Bad file descriptor] #6840

Yash-Singh1 opened this issue Aug 31, 2021 · 4 comments
Labels
Stale Inactive issues

Comments

@Yash-Singh1
Copy link

Yash-Singh1 commented Aug 31, 2021

馃悰 bug report

Build just freezes. It successfully finishes building, but never exits, same for the serve option. After around 5 minutes it exits with [Error: Bad file descriptor].

馃帥 Configuration (.babelrc, package.json, cli command)

https://github.com/Yash-Singh1/kanda-weather/blob/main/package.json

馃 Expected Behavior

It exits after building

馃槸 Current Behavior

The build never stops even if it is done. At the end it actually prints out:

[Error: Bad file descriptor]

馃拋 Possible Solution

Force quit the build after it is done and then manually start up the application. Of course, this is not the best option when testing or publishing in CI/CD. I am pretty sure there is some sort of

馃敠 Context

I am trying to build my React/Redux application

馃捇 Code Sample

https://github.com/Yash-Singh1/kanda-weather

馃實 Your Environment

Software Version(s)
Parcel ^2.0.0-beta.3.1
Node v16.3.0
npm/Yarn 7.19.1
Operating System Ubuntu 20.04.3 LTS

UPDATE:

I ran sudo npm run build as suggested over here #6463 (comment), and it ended up with a lot of parsing errors related to the parcel scoped dependencies internal javascript files.

@lukeknxt
Copy link

I was experiencing the same and managed to find a fix for my case. It doesn't appear to be the same as the OP given their package.json.

I'm running Ubuntu 20.04 on WSL2.

My package.json contained an entry point as per the docs:

  "source": "public/index.html",
  "scripts": {
    "start": "parcel",
    "build": "parcel build"
  },

Running npm run start or npm run build would result in [Error: Bad file descriptor].

However explicitly passing the entry point, such as npm run start public/index.html ran fine. Alternatively npx parcel public/index.html also worked.

@Yash-Singh1
Copy link
Author

I pass in the entrypoint to the CLI currently. I will try to specify the source option in the package.json. Another note is that the application successfully deploys to Vercel (my CD).

@CreativeCactus
Copy link

CreativeCactus commented Nov 23, 2021

For me, the solution was to ensure that parcel was installed in package.json.
Ad-hoc npx always resulted in [Error: Bad file descriptor].
Edit: Also try typescript and tsc if you use them.

@github-actions
Copy link

This issue has been automatically marked as stale because it has not had recent activity. It will be closed in 14 days if no further activity occurs.

@github-actions github-actions bot added the Stale Inactive issues label May 22, 2022
@github-actions github-actions bot closed this as completed Jun 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Stale Inactive issues
Projects
None yet
Development

No branches or pull requests

3 participants