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

npm install && npm build problems #8

Open
henksteenwijk opened this issue Dec 11, 2019 · 0 comments
Open

npm install && npm build problems #8

henksteenwijk opened this issue Dec 11, 2019 · 0 comments

Comments

@henksteenwijk
Copy link

Hi there,

First of thanks for the potential awesome package, i've been trying to get this running on my macbookpro for two days now and keep running into the same issues. I'm no expert when it comes to installing scripts like this but I love tinkering to find out where things go wrong.

Currently i run the npm install && npm build command which results in an error as followed:

henksteenwijk@Henks-MacBook-Pro glowbear % npm install && npm build           
npm WARN glowbear@1.0.0 No repository field.

removed 21 packages and audited 122 packages in 0.771s

2 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities

npm WARN build `npm build` called with no arguments. Did you mean to `npm run-script build`?
henksteenwijk@Henks-MacBook-Pro glowbear % 

As it states build is called without argument so I added "run-script" to the command which results in the following:

henksteenwijk@Henks-MacBook-Pro glowbear % npm install && npm run-script build 
npm WARN glowbear@1.0.0 No repository field.

audited 122 packages in 0.823s

2 packages are looking for funding
  run `npm fund` for details

found 0 vulnerabilities


> glowbear@1.0.0 build /Users/henksteenwijk/Documents/glowbear
> tsc

index.ts:71:24 - error TS2345: Argument of type 'TouchBarButton' is not assignable to parameter of type 'TouchBarLabel | TouchBarSpacer'.
  Type 'TouchBarButton' is missing the following properties from type 'TouchBarLabel': textColor, addListener, on, once, and 12 more.

 71             items.push(new TouchBar.TouchBarButton({
                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 72                 label: cmd.name,
    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
... 
 75                 click: fn
    ~~~~~~~~~~~~~~~~~~~~~~~~~
 76             }))
    ~~~~~~~~~~~~~~

index.ts:133:9 - error TS2322: Type '({ role: "about"; } | { type: "separator"; } | { role: "services"; submenu: undefined[]; } | { role: "hide"; } | { role: "hideothers"; } | { role: "unhide"; } | { role: "quit"; })[]' is not assignable to type 'Menu | MenuItemConstructorOptions[]'.
  Type '({ role: "about"; } | { type: "separator"; } | { role: "services"; submenu: undefined[]; } | { role: "hide"; } | { role: "hideothers"; } | { role: "unhide"; } | { role: "quit"; })[]' is not assignable to type 'MenuItemConstructorOptions[]'.
    Type '{ role: "about"; } | { type: "separator"; } | { role: "services"; submenu: undefined[]; } | { role: "hide"; } | { role: "hideothers"; } | { role: "unhide"; } | { role: "quit"; }' is not assignable to type 'MenuItemConstructorOptions'.
      Type '{ role: "hideothers"; }' is not assignable to type 'MenuItemConstructorOptions'.
        Types of property 'role' are incompatible.
          Type '"hideothers"' is not assignable to type '"window" | "hide" | "reload" | "close" | "copy" | "cut" | "paste" | "quit" | "minimize" | "undo" | "redo" | "pasteAndMatchStyle" | "delete" | "selectAll" | "forceReload" | "toggleDevTools" | ... 24 more ... | "windowMenu"'.

133         submenu: [
            ~~~~~~~

  node_modules/electron/electron.d.ts:11524:5
    11524     submenu?: (MenuItemConstructorOptions[]) | (Menu);
              ~~~~~~~
    The expected type comes from property 'submenu' which is declared here on type 'MenuItemConstructorOptions'


Found 2 errors.

npm ERR! code ELIFECYCLE
npm ERR! errno 2
npm ERR! glowbear@1.0.0 build: `tsc`
npm ERR! Exit status 2
npm ERR! 
npm ERR! Failed at the glowbear@1.0.0 build script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.

npm ERR! A complete log of this run can be found in:
npm ERR!     /Users/henksteenwijk/.npm/_logs/2019-12-11T08_44_47_617Z-debug.log

Mentioned log file gives me the following info:

0 info it worked if it ends with ok
1 verbose cli [
1 verbose cli   '/usr/local/Cellar/node/13.3.0/bin/node',
1 verbose cli   '/usr/local/bin/npm',
1 verbose cli   'run-script',
1 verbose cli   'build'
1 verbose cli ]
2 info using npm@6.13.2
3 info using node@v13.3.0
4 verbose run-script [ 'prebuild', 'build', 'postbuild' ]
5 info lifecycle glowbear@1.0.0~prebuild: glowbear@1.0.0
6 info lifecycle glowbear@1.0.0~build: glowbear@1.0.0
7 verbose lifecycle glowbear@1.0.0~build: unsafe-perm in lifecycle true
8 verbose lifecycle glowbear@1.0.0~build: PATH: /usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/node-gyp-bin:/Users/henksteenwijk/Documents/glowbear/node_modules/.bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin
9 verbose lifecycle glowbear@1.0.0~build: CWD: /Users/henksteenwijk/Documents/glowbear
10 silly lifecycle glowbear@1.0.0~build: Args: [ '-c', 'tsc' ]
11 silly lifecycle glowbear@1.0.0~build: Returned: code: 2  signal: null
12 info lifecycle glowbear@1.0.0~build: Failed to exec build script
13 verbose stack Error: glowbear@1.0.0 build: `tsc`
13 verbose stack Exit status 2
13 verbose stack     at EventEmitter.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/index.js:332:16)
13 verbose stack     at EventEmitter.emit (events.js:219:5)
13 verbose stack     at ChildProcess.<anonymous> (/usr/local/lib/node_modules/npm/node_modules/npm-lifecycle/lib/spawn.js:55:14)
13 verbose stack     at ChildProcess.emit (events.js:219:5)
13 verbose stack     at maybeClose (internal/child_process.js:1027:16)
13 verbose stack     at Process.ChildProcess._handle.onexit (internal/child_process.js:285:5)
14 verbose pkgid glowbear@1.0.0
15 verbose cwd /Users/henksteenwijk/Documents/glowbear
16 verbose Darwin 19.0.0
17 verbose argv "/usr/local/Cellar/node/13.3.0/bin/node" "/usr/local/bin/npm" "run-script" "build"
18 verbose node v13.3.0
19 verbose npm  v6.13.2
20 error code ELIFECYCLE
21 error errno 2
22 error glowbear@1.0.0 build: `tsc`
22 error Exit status 2
23 error Failed at the glowbear@1.0.0 build script.
23 error This is probably not a problem with npm. There is likely additional logging output above.
24 verbose exit [ 2, true ]

And then my troubleshooting skills come to an extreme halt, I have no idea how to move on. Any help would be highly appreciated.

I'm running on osx 10.15.1 btw I'm not sure if this changes anything regarding the build part.

Cheers,
Henk Steenwijk

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