Skip to content

Illegal instruction (core dumped) on Raspberry Pi 4 Model B Rev 1.5 (aarch64) #406

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

Closed
cascornelissen opened this issue Mar 25, 2025 · 14 comments · Fixed by unrs/unrs-resolver#69 or #443

Comments

@cascornelissen
Copy link

cascornelissen commented Mar 25, 2025

The recent v4 major switches the build tooling to rspack which is great for performance but unfortunately it makes it impossible to use the plugin on (my) Raspberry Pi for some reason. After trying to update eslint-import-resolver-typescript from 3.9.0 to 4.2.3 I'm met with this cryptic (rust?) error whenever I try to run eslint. It also creates a 250MB+ file named core.

$ eslint
Illegal instruction (core dumped)

This occurs in a GitLab pipeline with a private runner on a Raspberry Pi, both npm clean-install and eslint happen in node:22.14.0 images.

What's confusing me is that the node bindings do seem to exist at @unrs/rspack-resolver-binding-linux-arm64-gnu and @unrs/rspack-resolver-binding-linux-arm64-musl.

Since rust is a bit out of my comfort zone I thought I'd create this issue. If anyone has any pointers; I'm more than happy to debug a little ❤ I did manage to get the Node.js debug logs by executing DEBUG=* eslint;

MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/is-bun-module/dist/shared.js] [semver/functions/satisfies]: 0.476ms
MODULE 39: Module._load REQUEST semver/functions/lt parent: /builds/<project>/<repo>/node_modules/is-bun-module/dist/shared.js
MODULE 39: looking for "semver/functions/lt" in ["/builds/<project>/<repo>/node_modules/is-bun-module/dist/node_modules","/builds/<project>/<repo>/node_modules/is-bun-module/node_modules","/builds/<project>/<repo>/node_modules","/builds/<project>/node_modules","/builds/node_modules","/node_modules","/root/.node_modules","/root/.node_libraries","/usr/local/lib/node"]
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/is-bun-module/dist/shared.js] [semver/functions/lt]: 0.459ms
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/is-bun-module/dist/generic.js] [./shared]: 5.405ms
MODULE 39: Module._load REQUEST ./shared parent: /builds/<project>/<repo>/node_modules/is-bun-module/dist/generic.js
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/is-bun-module/dist/generic.js] [./shared]: 0.044ms
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/eslint-import-resolver-typescript/lib/index.cjs] [is-bun-module]: 8.213ms
MODULE 39: Module._load REQUEST rspack-resolver parent: /builds/<project>/<repo>/node_modules/eslint-import-resolver-typescript/lib/index.cjs
MODULE 39: looking for "rspack-resolver" in ["/builds/<project>/<repo>/node_modules/eslint-import-resolver-typescript/lib/node_modules","/builds/<project>/<repo>/node_modules/eslint-import-resolver-typescript/node_modules","/builds/<project>/<repo>/node_modules","/builds/<project>/node_modules","/builds/node_modules","/node_modules","/root/.node_modules","/root/.node_libraries","/usr/local/lib/node"]
MODULE 39: load "/builds/<project>/<repo>/node_modules/rspack-resolver/index.js" for module "/builds/<project>/<repo>/node_modules/rspack-resolver/index.js"
MODULE 39: Module._load REQUEST node:module parent: /builds/<project>/<repo>/node_modules/rspack-resolver/index.js
MODULE 39: load built-in module node:module
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/rspack-resolver/index.js] [node:module]: 0.14ms
MODULE 39: Module._load REQUEST node:fs parent: /builds/<project>/<repo>/node_modules/rspack-resolver/index.js
MODULE 39: load built-in module node:fs
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/rspack-resolver/index.js] [node:fs]: 0.067ms
MODULE 39: Module._load REQUEST ./resolver.linux-arm64-gnu.node parent: /builds/<project>/<repo>/node_modules/rspack-resolver/index.js
MODULE 39: RELATIVE: requested: ./resolver.linux-arm64-gnu.node from parent.id /builds/<project>/<repo>/node_modules/rspack-resolver/index.js
MODULE 39: looking for ["/builds/<project>/<repo>/node_modules/rspack-resolver"]
MODULE_TIMER 39 [/builds/<project>/<repo>/node_modules/rspack-resolver/index.js] [./resolver.linux-arm64-gnu.node]: 0.708ms
MODULE 39: Module._load REQUEST @unrs/rspack-resolver-binding-linux-arm64-gnu parent: /builds/<project>/<repo>/node_modules/rspack-resolver/index.js
MODULE 39: looking for "@unrs/rspack-resolver-binding-linux-arm64-gnu" in ["/builds/<project>/<repo>/node_modules/rspack-resolver/node_modules","/builds/<project>/<repo>/node_modules","/builds/<project>/node_modules","/builds/node_modules","/node_modules","/root/.node_modules","/root/.node_libraries","/usr/local/lib/node"]
MODULE 39: load "/builds/<project>/<repo>/node_modules/@unrs/rspack-resolver-binding-linux-arm64-gnu/resolver.linux-arm64-gnu.node" for module "/builds/<project>/<repo>/node_modules/@unrs/rspack-resolver-binding-linux-arm64-gnu/resolver.linux-arm64-gnu.node"
Illegal instruction (core dumped)
MODULE 27: Module._load REQUEST @npmcli/package-json parent: /usr/local/lib/node_modules/npm/lib/npm.js
MODULE 27: looking for "@npmcli/package-json" in ["/usr/local/lib/node_modules/npm/lib/node_modules","/usr/local/lib/node_modules/npm/node_modules","/usr/local/lib/node_modules","/usr/local/node_modules","/usr/node_modules","/node_modules","/root/.node_modules","/root/.node_libraries","/usr/local/lib/node"]
MODULE_TIMER 27 [/usr/local/lib/node_modules/npm/lib/npm.js] [@npmcli/package-json]: 0.665ms
MODULE 27: Module._load REQUEST ./utils/error-message.js parent: /usr/local/lib/node_modules/npm/lib/npm.js
MODULE 27: RELATIVE: requested: ./utils/error-message.js from parent.id /usr/local/lib/node_modules/npm/lib/npm.js
MODULE 27: looking for ["/usr/local/lib/node_modules/npm/lib"]
MODULE_TIMER 27 [/usr/local/lib/node_modules/npm/lib/npm.js] [./utils/error-message.js]: 0.816ms
MODULE 27: Module._load REQUEST node:fs parent: /usr/local/lib/node_modules/npm/lib/npm.js
MODULE 27: load built-in module node:fs
MODULE_TIMER 27 [/usr/local/lib/node_modules/npm/lib/npm.js] [node:fs]: 0.227ms
MODULE 27: Module._load REQUEST node:os parent: /usr/local/lib/node_modules/npm/lib/cli/exit-handler.js
MODULE 27: load built-in module node:os
MODULE_TIMER 27 [/usr/local/lib/node_modules/npm/lib/cli/exit-handler.js] [node:os]: 0.347ms
@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

Is that possible to reproduce it with gitlab.com?

@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

Please help to try [email protected] which adds new 4 targets support:

  • i686-pc-windows-msvc
  • armv7-unknown-linux-musleabihf
  • powerpc64le-unknown-linux-gnu
  • s390x-unknown-linux-gnu

@cascornelissen
Copy link
Author

Oh wow, thanks for the quick replies!

Is that possible to reproduce it with gitlab.com?

I don't think so without access to a Raspberry Pi. The Gitlab CI is just what triggers a build which runs on an on-premise Raspberry Pi. I assume the issue I'm facing is unrelated to Gitlab, I just included that detail for context.

Please help to try [email protected] which adds new 4 targets support:

Just tested 4.2.4, it throws the exact same error. As far as I do understand how this works the resolver-binding-linux-arm64-gnu should be valid since aarch64 === arm64 but some instruction inside of that binary is not supported by the Raspberry Pi.

@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

Then that seems an upstream issue.

cc @Brooooooklyn

@cascornelissen
Copy link
Author

Just went through with updating the OS on this Raspberry Pi from Debian 11 to 12 and unfortunately that also doesn't solve the issue. Looking forward to suggestions on how to properly resolve this 😊

@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

Maybe downgrading to v3 on CI could be a workaround.

v3 is still supported at https://github.com/import-js/eslint-import-resolver-typescript/tree/v3.x.

@cascornelissen
Copy link
Author

Yeah, I'm OK with sticking to v3 until this gets resolved. Just wanted to include some more information ❤

@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

I mean use v4 for development, downgrade to v3 on CI, technically they should result same but with different performance, this would also help us making sure no behavior changes between v3 and v4.

@cascornelissen
Copy link
Author

Not sure how in-depth we should go with regards to my setup. I actually have Renovate running which is trying to update this dependency. I'd like to use the same versions for reproducible builds, even if theoretically there should be no difference in behavior.

@JounQin
Copy link
Collaborator

JounQin commented Mar 26, 2025

That's OK, we will investigate later.

@JounQin
Copy link
Collaborator

JounQin commented Mar 29, 2025

@JounQin
Copy link
Collaborator

JounQin commented Mar 30, 2025

Friendly ping @cascornelissen

@cascornelissen
Copy link
Author

cascornelissen commented Apr 1, 2025

Apologies for the late reply, had a few busy days. Just tested 4.3.1 and unfortunately I'm still facing the same error;

$ npm ls eslint-import-resolver-typescript
└── [email protected]

$ eslint
Illegal instruction (core dumped)

@cascornelissen
Copy link
Author

Got excited by the email notification about the new release + closure of this issue and just wanted to confirm that v4.3.4 does indeed fix the issue on my end as well.

Thanks a bunch! ❤

renovate bot added a commit to andrei-picus-tink/auto-renovate that referenced this issue Apr 23, 2025
| datasource | package                           | from  | to    |
| ---------- | --------------------------------- | ----- | ----- |
| npm        | eslint-import-resolver-typescript | 4.3.1 | 4.3.4 |


## [v4.3.4](https://github.com/import-js/eslint-import-resolver-typescript/blob/HEAD/CHANGELOG.md#434)

##### Patch Changes

-   [#442](import-js/eslint-import-resolver-typescript#442) [`57611d9`](import-js/eslint-import-resolver-typescript@57611d9) Thanks [@JounQin](https://github.com/JounQin)! - fix: add more extension aliases for ts source/declaration files

-   [#444](import-js/eslint-import-resolver-typescript#444) [`bd45fcd`](import-js/eslint-import-resolver-typescript@bd45fcd) Thanks [@JounQin](https://github.com/JounQin)! - fix(deps): bump `unrs-resolver` which resolves [#406](import-js/eslint-import-resolver-typescript#406), [#409](import-js/eslint-import-resolver-typescript#409), [#437](import-js/eslint-import-resolver-typescript#437)


## [v4.3.3](https://github.com/import-js/eslint-import-resolver-typescript/blob/HEAD/CHANGELOG.md#433)

##### Patch Changes

-   [#433](import-js/eslint-import-resolver-typescript#433) [`834b11e`](import-js/eslint-import-resolver-typescript@834b11e) Thanks [@JounQin](https://github.com/JounQin)! - chore: bump `unrs-resolver` to v1.6.0


## [v4.3.2](https://github.com/import-js/eslint-import-resolver-typescript/blob/HEAD/CHANGELOG.md#432)

##### Patch Changes

-   [#427](import-js/eslint-import-resolver-typescript#427) [`dabba8e`](import-js/eslint-import-resolver-typescript@dabba8e) Thanks [@JounQin](https://github.com/JounQin)! - chore: bump `unrs-resolver` to v1.4.1
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
2 participants