You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Do or don't install a dependency, this does not effect outcome
What is the expected behavior?
It's expected that the pageBuilder Element be scaffolded and any dependencies be installed without issue.
What do you see instead?
yarn webiny extension
? What type of an extension do you want to create? Page Builder element
? Enter the extension name: calendly
? Enter the extension location: extensions/calendly
? Enter the package name: calendly
? Enter one or more NPM dependencies (optional):
✖ Could not create extension. Please check the logs below.
Error: Command failed with exit code 1: yarn install
➤ YN0000: · Yarn 4.5.0
➤ YN0000: ┌ Resolution step
➤ YN0082: │ @webiny/app-page-builder-elements@npm:0.0.0: No candidates found
➤ YN0000: └ Completed in 0s 557ms
➤ YN0000: · Failed with errors in 0s 573ms
at makeError (/Users/andrew/www/alifeinbinary-aws/node_modules/execa/lib/error.js:60:11)
at handlePromise (/Users/andrew/www/alifeinbinary-aws/node_modules/execa/index.js:118:26)
at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
at async runYarnInstall (/Users/andrew/www/alifeinbinary-aws/node_modules/@webiny/cli-plugin-scaffold/utils/runYarnInstall.js:10:3)
at async generateExtension (/Users/andrew/www/alifeinbinary-aws/node_modules/@webiny/cli-plugin-extensions/generateExtension.js:116:5) {
shortMessage: 'Command failed with exit code 1: yarn install',
command: 'yarn install',
escapedCommand: 'yarn install',
exitCode: 1,
signal: undefined,
signalDescription: undefined,
stdout: '➤ YN0000: · Yarn 4.5.0\n' +
'➤ YN0000: ┌ Resolution step\n' +
'➤ YN0082: │ @webiny/app-page-builder-elements@npm:0.0.0: No candidates found\n' +
'➤ YN0000: └ Completed in 0s 557ms\n' +
'➤ YN0000: · Failed with errors in 0s 573ms',
stderr: '',
failed: true,
timedOut: false,
isCanceled: false,
killed: false
}
Additional information
yarn -v
4.5.0
node -v
v20.12.1
Possible solution
Judging by the error it looks like the command tries to install @webiny/app-page-builder-elements during the scaffold process, however, it specifies version 0.0.0 which doesn't exist in NPM. Version 0.0.0 is the version webiny packages use internally when developing Webiny where packages reference a package build in a local directory within the Webiny codebase and not a compiled package from NPM. The command should populate the current webiny version in its place, like so: @webiny/app-page-builder-elements@npm:5.41.1
It looks like packages/cli-plugin-extensions/src/utils/setWebinyPackageVersions.ts is a utility for appending the current Webiny version to the @webiny package that gets installed alongside the PbElement, however, this utility does not get called around line 90 of packages/cli-plugin-extensions/src/generateExtension.ts, which perhaps it should.
If the Webiny team believes this this solution would be adequate, then I would gladly submit a PR with the fix.
The text was updated successfully, but these errors were encountered:
Version
5.41.1
Operating System
MacOS 14.7.1
Browser
N/A
What are the steps to reproduce this bug?
What is the expected behavior?
It's expected that the pageBuilder Element be scaffolded and any dependencies be installed without issue.
What do you see instead?
Additional information
yarn -v
4.5.0
node -v
v20.12.1
Possible solution
Judging by the error it looks like the command tries to install @webiny/app-page-builder-elements during the scaffold process, however, it specifies version 0.0.0 which doesn't exist in NPM. Version 0.0.0 is the version webiny packages use internally when developing Webiny where packages reference a package build in a local directory within the Webiny codebase and not a compiled package from NPM. The command should populate the current webiny version in its place, like so: @webiny/app-page-builder-elements@npm:5.41.1
It looks like
packages/cli-plugin-extensions/src/utils/setWebinyPackageVersions.ts
is a utility for appending the current Webiny version to the @webiny package that gets installed alongside the PbElement, however, this utility does not get called around line 90 ofpackages/cli-plugin-extensions/src/generateExtension.ts
, which perhaps it should.If the Webiny team believes this this solution would be adequate, then I would gladly submit a PR with the fix.
The text was updated successfully, but these errors were encountered: