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

Buffer() is deprecated #12

Closed
haugerud opened this issue Sep 24, 2021 · 5 comments
Closed

Buffer() is deprecated #12

haugerud opened this issue Sep 24, 2021 · 5 comments
Labels
bug Something isn't working

Comments

@haugerud
Copy link

Thanks for a nice piece of software!

Would it be possible to fix this issue? Or am I doing something wrong? No GUI appears when running the code.

haugerud@lap:~/src/keylight-control$ cat /etc/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=20.04
DISTRIB_CODENAME=focal
DISTRIB_DESCRIPTION="Ubuntu 20.04.3 LTS"

haugerud@lap:/src/keylight-control$ node --version
v10.19.0
haugerud@lap:
/src/keylight-control$ nodejs --version
v10.19.0
haugerud@lap:~/src/keylight-control$ npm --version
6.14.4

haugerud@lap:~/src/keylight-control$ npm run start

keylight-control@0.1.6 start /home/haugerud/src/keylight-control
webpack && qode dist/index.js

assets by path assets/.png 26.8 KiB
asset assets/app_icon.png 24.1 KiB [emitted] [from: src/assets/app_icon.png] [copied]
asset assets/bg.png 1.29 KiB [emitted] [from: src/assets/bg.png] [copied]
asset assets/power_off.png 554 bytes [emitted] [from: src/assets/power_off.png] [copied]
asset assets/power_on.png 531 bytes [emitted] [from: src/assets/power_on.png] [copied]
asset assets/bulb.png 271 bytes [emitted] [from: src/assets/bulb.png] [copied]
asset nodegui_core-1ea1e3f425fd036c191347fdd1f2e002.node 7.68 MiB [emitted] (auxiliary name: main)
asset index.js 1.67 MiB [emitted] (name: main)
runtime modules 793 bytes 4 modules
modules by path ./node_modules/ 1.39 MiB 330 modules
modules by path ./src/
.js 10.9 KiB
./src/index.js 5.14 KiB [built] [code generated]
./src/keylight.js 5.75 KiB [built] [code generated]
17 modules
webpack 5.53.0 compiled successfully in 1269 ms
(node:142536) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use qode --trace-deprecation ... to show where the warning was created)

@haugerud haugerud added the bug Something isn't working label Sep 24, 2021
@haugerud
Copy link
Author

I guess the deprecation part is just a warning. When testing 'hello world' the gui appears:

haugerud@lap:~/src/nodegui-starter$ npm run start

nodegui-starter@1.0.0 start /home/haugerud/src/nodegui-starter
webpack && qode ./dist/index.js

asset nodegui_core-7e708aeaa743573591eb69defd359ae8.node 8.29 MiB [emitted] (auxiliary name: main)
asset index.js 1.35 MiB [emitted] (name: main)
asset 22c8769d0d1e03941f73a69e7842ebe4.png 6.58 KiB [emitted] [immutable] [from: assets/logox200.png] (auxiliary name: main)
runtime modules 793 bytes 4 modules
modules by path ./node_modules/@nodegui/nodegui/dist/lib/ 491 KiB 214 modules
modules by path ./node_modules/postcss/lib/.js 479 KiB 25 modules
modules by path ./node_modules/source-map/ 99.4 KiB 11 modules
modules by path ./node_modules/cuid/ 2.88 KiB 4 modules
modules by path ./node_modules/chalk/ 12.1 KiB
./node_modules/chalk/index.js 6.29 KiB [built] [code generated]
./node_modules/chalk/node_modules/supports-color/index.js 2.71 KiB [built] [code generated]
./node_modules/chalk/templates.js 3.06 KiB [built] [code generated]
modules by path ./node_modules/color-convert/
.js 20.3 KiB
./node_modules/color-convert/index.js 1.68 KiB [built] [code generated]
./node_modules/color-convert/conversions.js 16.5 KiB [built] [code generated]
./node_modules/color-convert/route.js 2.17 KiB [built] [code generated]
16 modules
webpack 5.53.0 compiled successfully in 2737 ms

@justinforlenza
Copy link
Owner

Hey, sorry just getting to this, this appears to be an issue with the node bonjour package, which hasnt been updated in 5 years...

@removogel
Copy link

Same to me. It worked very fine for 30 minutes. The i created a launcher entry for the AppImage and started it maybe a few times and had more than one instance running.
Now (even after system reboot) the application window stays empty, see screenshot.
At the same time i can still control the light via iOS app.

image

When starting from CMD i get following error

'/home/user/Apps/Keylight_Controller-x86_64.AppImage' 
Welcome to Node.js v14.2.0.
Type ".help" for more information.
> (node:6403) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead.
(Use `Keylight_Controller-x86_64.AppImage --trace-deprecation ...` to show where the warning was created)
> 

@justinforlenza
Copy link
Owner

@removogel

So the "Buffer() is deprecated" is a warning because of one of the dependencies being used for this app. And has always been there, and hasn't caused the app to not work.

I thought I had closed this issue previously, so if you wouldn't mind creating a new issue using the bug template so I could more directly support your issue you are experiencing

@thediveo
Copy link

thediveo commented Jan 2, 2023

The problem is that newer nodejs versions now block execution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants