Erreur au lancement sous windows 10 à partir des sources

Hi,

Installation depuis les sources après avoir installé la dernière version de nodejs

nlb@inspiron MINGW64 ~/audio/open-stage-control (master)
$ npm start

> open-stage-control@0.46.1 start C:\Users\nlb\audio\open-stage-control
> electron app/


App threw an error during load
C:\Users\nlb\audio\open-stage-control\app\server\open-stage-control-server.js:21606
        ...this._options.zlibInflateOptions,
        ^^^

SyntaxError: Unexpected token ...
    at createScript (vm.js:74:10)
    at Object.runInThisContext (vm.js:116:10)
    at Module._compile (module.js:533:28)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:503:32)
    at tryModuleLoad (module.js:466:12)
    at Function.Module._load (module.js:458:3)
    at Module.require (module.js:513:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (C:\Users\nlb\audio\open-stage-control\app\index.js:1:156)

nlb@inspiron MINGW64 ~/audio/open-stage-control (master)
$ npm --version
6.9.0

nlb@inspiron MINGW64 ~/audio/open-stage-control (master)
$ node --version
v12.3.0

Une idée ? Merci

J’ai corrigé ça la semaine dernière, tu as peut-être oublié une étape dans la procédure:

git pull
npm install
npm run build

hello,

Non je n’ai pas oublié d’étapes.
Je viens de le faire sur un autre pc sous windows 10 même souci.

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ npm start

> open-stage-control@0.46.1 start D:\audio\open-stage-control
> electron app/


App threw an error during load
D:\audio\open-stage-control\app\server\open-stage-control-server.js:21606
        ...this._options.zlibInflateOptions,
        ^^^

SyntaxError: Unexpected token ...
    at createScript (vm.js:74:10)
    at Object.runInThisContext (vm.js:116:10)
    at Module._compile (module.js:533:28)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:503:32)
    at tryModuleLoad (module.js:466:12)
    at Function.Module._load (module.js:458:3)
    at Module.require (module.js:513:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (D:\audio\open-stage-control\app\index.js:1:156)

la version 0.46.1 installée depuis l’exécutable marche très bien.

Tu es bien sur le commit 496e743a3d5c8b5feaf70cb38e6e14ee6ef3c77f ? (git rev-parse HEAD pour vérifier le commit actuel).

Si c’est le cas, peux-tu exécuter ça et me donner le log complet si ça ne fonctionne pas (pas seulement le log après npm start) ?

rd /s /q "node_modules"
npm install
npm run build
npm start

oui oui je suis sur le bon commit normal (vu que je clone le master non ?)

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ git rev-parse HEAD
496e743a3d5c8b5feaf70cb38e6e14ee6ef3c77f

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ rd /s /q "node_modules"
bash: rd: command not found

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$

rd pas disponible sous mon git bash…
of course :slight_smile:

rm -rf "node_modules"

ceci dit je ne vois pas pourquoi virer ce dossier vu que je pars d’un git clone tout frais tout neuf.

Effectivement, pas besoin de le supprimer dans ce cas, je veux bien le log complet du coup si tu peux.

peux-tu m’indiquer quel fichier log tu veux ? Où se cache-t’il ?

Il s’agit juste des messages de la console pendand npm install et npm run build

Voici voilà

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ git rev-parse HEAD
496e743a3d5c8b5feaf70cb38e6e14ee6ef3c77f

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ rd /s /q "node_modules"
bash: rd: command not found

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ rm -rf "node_modules"

nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ npm install

> @serialport/bindings@2.0.8 install D:\audio\open-stage-control\node_modules\@s                                                                                                                                                                                               erialport\bindings
> prebuild-install --tag-prefix @serialport/bindings@ || node-gyp rebuild


> node-sass@4.12.0 install D:\audio\open-stage-control\node_modules\node-sass
> node scripts/install.js

Cached binary found at C:\Users\nlb\AppData\Roaming\npm-cache\node-sass\4.12.0\w                                                                                                                                                                                               in32-x64-72_binding.node

> core-js@2.6.8 postinstall D:\audio\open-stage-control\node_modules\@babel\poly                                                                                                                                                                                               fill\node_modules\core-js
> node -e "try { require('./scripts/postinstall'); } catch (e) { /* empty */ }"

Thank you for using core-js ( https://github.com/zloirock/core-js )!

Please consider supporting of core-js on Open Collective or Patreon:
> https://opencollective.com/core-js
> https://www.patreon.com/zloirock

Also, the author of core-js ( https://github.com/zloirock ) is looking for a goo                                                                                                                                                                                               d job -)


> core-js-pure@3.1.2 postinstall D:\audio\open-stage-control\node_modules\core-j                                                                                                                                                                                               s-pure
> node -e "try { require('./scripts/postinstall'); } catch (e) { /* empty */ }"

Thank you for using core-js ( https://github.com/zloirock/core-js )!

Please consider supporting of core-js on Open Collective or Patreon:
> https://opencollective.com/core-js
> https://www.patreon.com/zloirock

Also, the author of core-js ( https://github.com/zloirock ) is looking for a goo                                                                                                                                                                                               d job -)


> electron@1.8.8 postinstall D:\audio\open-stage-control\node_modules\electron
> node install.js


> node-sass@4.12.0 postinstall D:\audio\open-stage-control\node_modules\node-sas                                                                                                                                                                                               s
> node scripts/build.js

Binary found at D:\audio\open-stage-control\node_modules\node-sass\vendor\win32-                                                                                                                                                                                               x64-72\binding.node
Testing binary
Binary is fine

> nodemon@1.19.0 postinstall D:\audio\open-stage-control\node_modules\nodemon
> node bin/postinstall || exit 0


> open-stage-control@0.46.1 postinstall D:\audio\open-stage-control
> echo '\033[36m=> Dependencies installed successfully. Run "npm run build" to b                                                                                                                                                                                               uild the assets.\033[0m
'

npm WARN optional SKIPPING OPTIONAL DEPENDENCY: electron-installer-debian@github                                                                                                                                                                                               :electron-userland/electron-installer-debian#ec1dc4b (node_modules\electron-inst                                                                                                                                                                                               aller-debian):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for electron-                                                                                                                                                                                               installer-debian@1.1.1: wanted {"os":"darwin,linux","arch":"any"} (current: {"os                                                                                                                                                                                               ":"win32","arch":"x64"})
npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.9 (node_modules\fse                                                                                                                                                                                               vents):
npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@                                                                                                                                                                                               1.2.9: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}                                                                                                                                                                                               )

added 971 packages from 585 contributors and audited 10397 packages in 60.056s
found 0 vulnerabilities


nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ npm run build

> open-stage-control@0.46.1 build D:\audio\open-stage-control
> npm run build-css && npm run build-js && node scripts/copy-assets.js && echo '                                                                                                                                                                                               \033[36m=> JS and CSS assets built successfully. Run "npm run package" to build                                                                                                                                                                                                an executable or "npm start" to run the app.\033[0m
'


> open-stage-control@0.46.1 build-css D:\audio\open-stage-control
> node scripts/build-css.js


> open-stage-control@0.46.1 build-js D:\audio\open-stage-control
> npm run build-launcher-js && npm run build-client-js -- --prod && npm run buil                                                                                                                                                                                               d-server-js


> open-stage-control@0.46.1 build-launcher-js D:\audio\open-stage-control
> node scripts/build-launcher.js


> open-stage-control@0.46.1 build-client-js D:\audio\open-stage-control
> node scripts/build-client.js "--prod"

=> Building minified client bundle, this may take a while...

> open-stage-control@0.46.1 build-server-js D:\audio\open-stage-control
> node scripts/build-server.js


nlb@speedy MINGW64 /d/audio/open-stage-control (master)
$ npm start

> open-stage-control@0.46.1 start D:\audio\open-stage-control
> electron app/


App threw an error during load
D:\audio\open-stage-control\app\server\open-stage-control-server.js:21606
        ...this._options.zlibInflateOptions,
        ^^^

SyntaxError: Unexpected token ...
    at createScript (vm.js:74:10)
    at Object.runInThisContext (vm.js:116:10)
    at Module._compile (module.js:533:28)
    at Object.Module._extensions..js (module.js:580:10)
    at Module.load (module.js:503:32)
    at tryModuleLoad (module.js:466:12)
    at Function.Module._load (module.js:458:3)
    at Module.require (module.js:513:17)
    at require (internal/module.js:11:18)
    at Object.<anonymous> (D:\audio\open-stage-control\app\index.js:1:156)
^C^CTerminer le programme de commandes (O/N)▒?

Est-ce que tu peux poster le contenu du fichier scripts/build-server.js ? Il n’y qu’en le modifiant que j’arrive à reproduire l’erreur.

Voici donc (depuis mon ordi inspiron)

nlb@inspiron MINGW64 ~/audio/open-stage-control (master)
$ cat scripts/build-server.js
var build = require('./build'),
    babelify = require('babelify')

build({
    input: '../src/server/index.js',
    output: '../app/server/open-stage-control-server.js',
    options: {
        commonDir: false,
        ignoreMissing: true,
        debug: true,
        builtins: false,
        commondir: false,
        insertGlobalVars: {
            __filename: true,
            __dirname: true,
            process: true,
            electron: true,
            global: true
        },
        browserField: false,
    },
    ignore: 'serialport',
    exclude: 'electron',
    transforms: [
        [babelify, {
            'presets': [
                ['@babel/env', {
                    'targets': {
                        'node': '6',
                    },
                    'useBuiltIns': 'usage',
                    'corejs': 3
                }]
            ],
            'plugins': ['@babel/plugin-proposal-object-rest-spread'],
            'global': true,
            'ignore': [/^(?!.*\/ws\/)/]
        }]
    ]
})()

Ok merci, je ne comprends pas ce qui pose problème, je te redis si j’ai une idée.

Ok. il n’y a pas d’urgences.

Pour info même résultat avec

Administrateur@webdev MINGW64 /c/audio
$ git --version
git version 2.21.0.windows.1

Administrateur@webdev MINGW64 /c/audio
$ node --version
v10.15.3

Administrateur@webdev MINGW64 /c/audio
$ npm --version
6.4.1

Si ça peut t’aider à éliminer des pistes.bon courage