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

ERR_BUFFER_OUT_OF_BOUNDS with NodeJS v22.7.0 #585

Open
LeoSpyke opened this issue Sep 2, 2024 · 0 comments
Open

ERR_BUFFER_OUT_OF_BOUNDS with NodeJS v22.7.0 #585

LeoSpyke opened this issue Sep 2, 2024 · 0 comments

Comments

@LeoSpyke
Copy link

LeoSpyke commented Sep 2, 2024

This is the exception that occurs when I start bos (telegram command) after upgrading to NodeJS v22.7.0:

[...]
 (node:181028) [DEP0040] DeprecationWarning: The `punycode` module is deprecated. Please use a userland alternative instead.
 (Use `node --trace-deprecation ...` to show where the warning was created)
 node:internal/buffer:1066
       throw new ERR_BUFFER_OUT_OF_BOUNDS('length');
       ^
 RangeError [ERR_BUFFER_OUT_OF_BOUNDS]: "length" is outside of buffer bounds
     at proto.utf8Write (node:internal/buffer:1066:13)
     at Op.writeStringBuffer [as fn] (/my/custom/path/balanceofsatoshis/node_modules/protobufjs/src/writer_buffer.js:61:13)
     at BufferWriter.finish (/my/custom/path/balanceofsatoshis/node_modules/protobufjs/src/writer.js:453:14)
     at /my/custom/path/balanceofsatoshis/node_modules/@grpc/proto-loader/build/src/index.js:177:109
     at Array.map (<anonymous>)
     at createPackageDefinition (/my/custom/path/balanceofsatoshis/node_modules/@grpc/proto-loader/build/src/index.js:177:39)
     at loadSync (/my/custom/path/balanceofsatoshis/node_modules/@grpc/proto-loader/build/src/index.js:223:12)
     at module.exports (/my/custom/path/balanceofsatoshis/node_modules/lightning/lnd_grpc/api_for_proto.js:18:42)
     at /my/custom/path/balanceofsatoshis/node_modules/lightning/lnd_grpc/authenticated_lnd_grpc.js:71:24
     at Array.reduce (<anonymous>)
     at module.exports (/my/custom/path/balanceofsatoshis/node_modules/lightning/lnd_grpc/authenticated_lnd_grpc.js:66:29)
     at asyncAuto.lnd (/my/custom/path/balanceofsatoshis/lnd/authenticated_lnd.js:27:26)
     at runTask (/my/custom/path/balanceofsatoshis/node_modules/async/auto.js:293:13)
     at /my/custom/path/balanceofsatoshis/node_modules/async/auto.js:233:31
     at processQueue (/my/custom/path/balanceofsatoshis/node_modules/async/auto.js:243:13)
     at taskComplete (/my/custom/path/balanceofsatoshis/node_modules/async/auto.js:259:9) {
   code: 'ERR_BUFFER_OUT_OF_BOUNDS'
 }

I'm running it on a Debian 12 via systemd unit.
I'm not a Node dev but, could it be related with this?

The current workaround I found is simply to revert NodeJS to the latest working version (v22.6.0) and marking the packages with apt-hold in order to avoid updating it by accident until a patch is released.

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

1 participant