Skip to content

NodeGUI and nut.js #231

Description

@peec

Version
next.

Short overview

Issue occurs on

  • Virtual machine
  • Docker container
  • Dev/Host system

Detailed error description

I am using https://github.com/nodegui/react-nodegui-starter as a starter. Dont use electron its too slow.

After npm installing nut.js, and starting it using nodegui react, i get this error ( libnut.node could not be found ).

➜  robot2 git:(master) ✗ npm run start                                   

> react-nodegui-starter@1.0.0 start
> qode ./dist/index.js

/Users/peec/Desktop/robot2/dist/index.js:28402
  throw err;
  ^

Error: Could not locate the bindings file. Tried:
 → /Users/peec/Desktop/robot2/build/libnut.node
 → /Users/peec/Desktop/robot2/build/Debug/libnut.node
 → /Users/peec/Desktop/robot2/build/Release/libnut.node
 → /Users/peec/Desktop/robot2/out/Debug/libnut.node
 → /Users/peec/Desktop/robot2/Debug/libnut.node
 → /Users/peec/Desktop/robot2/out/Release/libnut.node
 → /Users/peec/Desktop/robot2/Release/libnut.node
 → /Users/peec/Desktop/robot2/build/default/libnut.node
 → /Users/peec/Desktop/robot2/compiled/14.2.0/darwin/x64/libnut.node
 → /Users/peec/Desktop/robot2/addon-build/release/install-root/libnut.node
 → /Users/peec/Desktop/robot2/addon-build/debug/install-root/libnut.node
 → /Users/peec/Desktop/robot2/addon-build/default/install-root/libnut.node
 → /Users/peec/Desktop/robot2/lib/binding/node-v83-darwin-x64/libnut.node
    at bindings (/Users/peec/Desktop/robot2/dist/index.js:28393:9)
    at Object../node_modules/@nut-tree/libnut-darwin/index.js (/Users/peec/Desktop/robot2/dist/index.js:20923:90)
    at __webpack_require__ (/Users/peec/Desktop/robot2/dist/index.js:749:30)
    at fn (/Users/peec/Desktop/robot2/dist/index.js:60:20)
    at webpackContext (/Users/peec/Desktop/robot2/dist/index.js:20834:9)
    at Object../node_modules/@nut-tree/libnut/index.js (/Users/peec/Desktop/robot2/dist/index.js:24997:97)
    at __webpack_require__ (/Users/peec/Desktop/robot2/dist/index.js:749:30)
    at fn (/Users/peec/Desktop/robot2/dist/index.js:60:20)
    at Object../node_modules/@nut-tree/nut-js/dist/lib/provider/native/libnut-keyboard-action.class.js (/Users/peec/Desktop/robot2/dist/index.js:26485:16)
    at __webpack_require__ (/Users/peec/Desktop/robot2/dist/index.js:749:30) {
  tries: [
    '/Users/peec/Desktop/robot2/build/libnut.node',
    '/Users/peec/Desktop/robot2/build/Debug/libnut.node',
    '/Users/peec/Desktop/robot2/build/Release/libnut.node',
    '/Users/peec/Desktop/robot2/out/Debug/libnut.node',
    '/Users/peec/Desktop/robot2/Debug/libnut.node',
    '/Users/peec/Desktop/robot2/out/Release/libnut.node',
    '/Users/peec/Desktop/robot2/Release/libnut.node',
    '/Users/peec/Desktop/robot2/build/default/libnut.node',
    '/Users/peec/Desktop/robot2/compiled/14.2.0/darwin/x64/libnut.node',
    '/Users/peec/Desktop/robot2/addon-build/release/install-root/libnut.node',
    '/Users/peec/Desktop/robot2/addon-build/debug/install-root/libnut.node',
    '/Users/peec/Desktop/robot2/addon-build/default/install-root/libnut.node',
    '/Users/peec/Desktop/robot2/lib/binding/node-v83-darwin-x64/libnut.node'
  ]
}

Steps to reproduce error

Additional content

Please provide any (mandatory) additional data to reproduce the error (Dockerfiles etc.)

package.json

{
  "name": "react-nodegui-starter",
  "version": "1.0.0",
  "main": "index.js",
  "author": "Atul R <atulanand94@gmail.com>",
  "license": "MIT",
  "private": true,
  "scripts": {
    "build": "webpack -p",
    "dev": "webpack --mode=development",
    "start": "qode ./dist/index.js",
    "debug": "qode --inspect ./dist/index.js",
    "rebuild": "npm rebuild --node-dir=node_modules/@nodegui/qode"
  },
  "dependencies": {
    "@nodegui/react-nodegui": "^0.10.2",
    "@nut-tree/nut-js": "^1.6.1-next.20210408195718",
    "open": "^7.2.1",
    "react": "^16.13.1",
    "robotjs": "^0.6.0"
  },
  "devDependencies": {
    "@babel/core": "^7.11.6",
    "@babel/preset-env": "^7.11.5",
    "@babel/preset-react": "^7.10.4",
    "@babel/preset-typescript": "^7.10.4",
    "@nodegui/packer": "^1.4.1",
    "@types/node": "^14.11.1",
    "@types/react": "^16.9.49",
    "@types/webpack-env": "^1.15.3",
    "babel-loader": "^8.1.0",
    "clean-webpack-plugin": "^3.0.0",
    "file-loader": "^6.1.0",
    "fork-ts-checker-webpack-plugin": "^5.2.0",
    "native-addon-loader": "^2.0.1",
    "typescript": "^4.0.3",
    "webpack": "^4.44.2",
    "webpack-cli": "^3.3.12"
  }
}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions