alexa-games / skill-flow-builder

Development suite that helps you create narrative-driven Alexa skills, including a GUI editor and CLI
Other
69 stars 19 forks source link

Bug: "The engine "vscode" appears to be invalid." - package builds but fails on install #32

Open ghost opened 3 years ago

ghost commented 3 years ago

Bug Report

Skill Flow Builder Version

2.0.0

ASK CLI Version

2.22.0

Current Behavior

SFB won't install

Expected Behavior

Should install

Steps to Reproduce

Follow exact steps on https://github.com/alexa-games/skill-flow-builder

Additional Information

Operating System

Ubuntu 20.04

Node Version

v14.15.3

Output

Note in particular "The engine "vscode" appears to be invalid."

yarn install
yarn install v1.22.4
warning package.json: License should be a valid SPDX license expression
info No lockfile found.
warning sfb-skill-package@1.0.0: License should be a valid SPDX license expression
[1/4] Resolving packages...
warning lerna > @lerna/bootstrap > @lerna/run-lifecycle > npm-lifecycle > node-gyp > request@2.88.2: request has been deprecated, see https://github.com/request/request/issues/3142
warning lerna > @lerna/bootstrap > @lerna/run-lifecycle > npm-lifecycle > node-gyp > request > har-validator@5.1.5: this library is no longer supported
warning lerna > @lerna/create > globby > fast-glob > micromatch > snapdragon > source-map-resolve > resolve-url@0.2.1: https://github.com/lydell/resolve-url#deprecated
warning lerna > @lerna/create > globby > fast-glob > micromatch > snapdragon > source-map-resolve > urix@0.1.0: Please see https://github.com/lydell/urix#deprecated
warning lerna > @lerna/bootstrap > @lerna/symlink-binary > @lerna/create-symlink > @zkochan/cmd-shim > mkdirp-promise@5.0.1: This package is broken and no longer maintained. 'mkdirp' itself supports promises now, please switch to that.
[2/4] Fetching packages...
[3/4] Linking dependencies...
warning "lerna > @lerna/version > @lerna/github-client > @octokit/rest > @octokit/plugin-request-log@1.0.2" has unmet peer dependency "@octokit/core@>=3".
[4/4] Building fresh packages...
success Saved lockfile.
warning Your current version of Yarn is out of date. The latest version is "1.22.5", while you're on "1.22.4".
info To upgrade, run the following command:
$ sudo apt-get update && sudo apt-get install yarn
$ npm run build-modules
npm WARN lifecycle The node binary used for scripts is /tmp/yarn--1609872913064-0.20474591793012542/node but npm is using /usr/bin/node itself. Use the `--scripts-prepend-node-path` option to include the path for the node binary npm was executed with.

> sfb-skill-package@1.0.0 build-modules /home/ubuntu/scripts/alexa/skill-flow-builder/skill-flow-builder
> cd packages && node buildAll -c

  sfb-util: Cleaning......
✔ sfb-util: Clean finished in 577 ms.
  sfb-polly: Cleaning......
✔ sfb-polly: Clean finished in 612 ms.
  sfb-f: Cleaning......
✔ sfb-f: Clean finished in 577 ms.
  sfb-test: Cleaning......
✔ sfb-test: Clean finished in 519 ms.
  sfb-skill: Cleaning......
✔ sfb-skill: Clean finished in 458 ms.
  sfb-vscode-extension: Cleaning......
✔ sfb-vscode-extension: Clean finished in 472 ms.
  sfb-story-debugger: Cleaning......
✔ sfb-story-debugger: Clean finished in 448 ms.
  sfb-cli: Cleaning......
✔ sfb-cli: Clean finished in 450 ms.
  sfb-editor: Cleaning......
✔ sfb-editor: Clean finished in 460 ms.
Finished in 4580 ms.
  sfb-util: Building......
✔ sfb-util: Build finished in 22347 ms.
  sfb-polly: Building......
✔ sfb-polly: Build finished in 34365 ms.
  sfb-f: Building......
✔ sfb-f: Build finished in 47123 ms.
  sfb-test: Building......
✔ sfb-test: Build finished in 36000 ms.
  sfb-skill: Building......
✔ sfb-skill: Build finished in 34044 ms.
  sfb-vscode-extension: Building......
✔ sfb-vscode-extension: Build finished in 41275 ms.
  sfb-story-debugger: Building......
✔ sfb-story-debugger: Build finished in 39299 ms.
  sfb-cli: Building......
✔ sfb-cli: Build finished in 53671 ms.
  sfb-editor: Building......
✔ sfb-editor: Build finished in 260909 ms.
Finished in 569041 ms.
Done in 598.99s.
[tvDev :~/scripts/alexa/skill-flow-builder/skill-flow-builder]$ yarn global add @alexa-games/sfb-cli
yarn global v1.22.4
warning package.json: License should be a valid SPDX license expression
[1/4] Resolving packages...
[2/4] Fetching packages...
warning @alexa-games/sfb-vscode-extension@2.1.0: The engine "vscode" appears to be invalid.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Installed "@alexa-games/sfb-cli@2.1.0" with binaries:
      - alexa-sfb
Done in 13.60s.
[tvDev :~/scripts/alexa/skill-flow-builder/skill-flow-builder]$ yarn global add /full/path/to/AlexaGamesSiillFlowBuilder/packages/sfb-cli
yarn global v1.22.4
warning package.json: License should be a valid SPDX license expression
[1/4] Resolving packages...
error Package "/full/path/to/AlexaGamesSkillFlowBuilder/packages/sfb-cli" refers to a non-existing file '"/full/path/to/AlexaGamesSkillFlowBuilder/packages/sfb-cli"'.
info Visit https://yarnpkg.com/en/docs/cli/global for documentation about this command.
[tvDev :~/scripts/alexa/skill-flow-builder/skill-flow-builder]$ alexa-sfb new test
alexa-sfb: command not found
anfazio commented 3 years ago

Hi, thanks for the bug report. I think this is probably an issue with the standard yarn installation on Ubuntu. It looks like you have to manually add the output of yarn global bin to your PATH directory and ensure you are using the actual path to your sfb-cli directory rather than the example path.

e.g.

$> yarn global bin
/home/ubuntu/.yarn/bin
$> export PATH="$PATH:/home/ubuntu/.yarn/bin"
$> yarn global add /home/ubuntu/scripts/alexa/skill-flow-builder/skill-flow-builder/packages/sfb-cli
$> alexa-sfb new test
ghost commented 3 years ago

Good catch! Seems to be OK in spite of warning about "invalid vscode engine"

[1/4] Resolving packages...
[2/4] Fetching packages...
warning @alexa-games/sfb-vscode-extension@2.1.0: The engine "vscode" appears to be invalid.
warning @alexa-games/sfb-vscode-extension@2.1.0: The engine "vscode" appears to be invalid.
[3/4] Linking dependencies...
[4/4] Building fresh packages...
success Installed "@alexa-games/sfb-cli@2.1.0" with binaries:
      - alexa-sfb
Done in 2.63s.
[tvDev :~/scripts/alexa/skill-flow-builder]$ alexa-sfb new test
  Copying /home/ubuntu/.config/yarn/global/node_modules/@alexa-games/sfb-cli/samples/example_story/* to /home/ubuntu/scripts/alexa/skill-flow-builder/test...
✔ New story test is ready.

Perhaps a note to add to the docs? Thanks again!

troyam commented 3 years ago

@digitaltoast here is the same.

✘ sfb-vscode-extension: Build failed.

OS: Mac OS Big Sur

Maybe's a problem with the vscode directory.