-
-
Notifications
You must be signed in to change notification settings - Fork 22
Description
This project looks great, and I'm really excited about the prospect of finally being able to manage the front-end dependencies of our Composer packages!
As of yet, I haven't had any luck trying it out though - every composer install
or composer update
ends with an npm error.
Here's the (verbose) output:
$ composer install -v
KODUS 2 installer enabled
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Dependency resolution completed in 0.002 seconds
Analyzed 290 packages to resolve dependencies
Analyzed 1058 rules to resolve dependencies
Nothing to install or update
Package http-interop/http-server-handler is abandoned, you should avoid using it. Use psr/http-server-handler instead.
Package http-interop/http-server-middleware is abandoned, you should avoid using it. Use psr/http-server-middleware instead.
Generating autoload files
Merging Composer dependencies in the asset package
Installing npm dependencies
npm ERR! Invalid version: "dev-master"
npm ERR! A complete log of this run can be found in:
npm ERR! /home/mindplay/.npm/_logs/2018-09-06T09_16_38_957Z-debug.log
Fallback to previous state for the Asset package
Fallback to previous state for Composer
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Dependency resolution completed in 0.003 seconds
Analyzed 290 packages to resolve dependencies
Analyzed 1058 rules to resolve dependencies
Nothing to install or update
Package http-interop/http-server-handler is abandoned, you should avoid using it. Use psr/http-server-handler instead.
Package http-interop/http-server-middleware is abandoned, you should avoid using it. Use psr/http-server-middleware instead.
Generating autoload files
[RuntimeException]
The asset manager ended with an error
Exception trace:
() at /mnt/c/workspace/test/staging_project/vendor/foxy/foxy/Solver/Solver.php:108
Foxy\Solver\Solver->solve() at /mnt/c/workspace/test/staging_project/vendor/foxy/foxy/Foxy.php:131
Foxy\Foxy->solveAssets() at n/a:n/a
call_user_func() at phar:///usr/bin/composer/src/Composer/EventDispatcher/EventDispatcher.php:176
Composer\EventDispatcher\EventDispatcher->doDispatch() at phar:///usr/bin/composer/src/Composer/EventDispatcher/EventDispatcher.php:96
Composer\EventDispatcher\EventDispatcher->dispatchScript() at phar:///usr/bin/composer/src/Composer/Installer.php:323
Composer\Installer->run() at phar:///usr/bin/composer/src/Composer/Command/InstallCommand.php:119
Composer\Command\InstallCommand->execute() at phar:///usr/bin/composer/vendor/symfony/console/Command/Command.php:242
Symfony\Component\Console\Command\Command->run() at phar:///usr/bin/composer/vendor/symfony/console/Application.php:843
Symfony\Component\Console\Application->doRunCommand() at phar:///usr/bin/composer/vendor/symfony/console/Application.php:193
Symfony\Component\Console\Application->doRun() at phar:///usr/bin/composer/src/Composer/Console/Application.php:251
Composer\Console\Application->doRun() at phar:///usr/bin/composer/vendor/symfony/console/Application.php:117
Symfony\Component\Console\Application->run() at phar:///usr/bin/composer/src/Composer/Console/Application.php:100
Composer\Console\Application->run() at phar:///usr/bin/composer/bin/composer:59
require() at /usr/bin/composer:24
install [--prefer-source] [--prefer-dist] [--dry-run] [--dev] [--no-dev] [--no-custom-installers] [--no-autoloader] [--no-scripts] [--no-progress] [--no-suggest] [-v|vv|vvv|--verbose] [-o|--optimize-autoloader] [-a|--classmap-authoritative] [--apcu-autoloader] [--ignore-platform-reqs] [--] [<packages>]...
Here's the output of the debug log:
0 info it worked if it ends with ok
1 verbose cli [ '/usr/bin/node', '/usr/bin/npm', 'install' ]
2 info using npm@6.3.0
3 info using node@v9.11.2
4 verbose npm-session d6096af3659c374f
5 silly install runPreinstallTopLevelLifecycles
6 silly preinstall staging_project
7 info lifecycle @~preinstall: @
8 silly install loadCurrentTree
9 silly install readLocalPackageData
10 timing stage:loadCurrentTree Completed in 12ms
11 silly install loadIdealTree
12 silly install cloneCurrentTreeToIdealTree
13 timing stage:loadIdealTree:cloneCurrentTree Completed in 0ms
14 silly install loadShrinkwrap
15 timing stage:loadIdealTree:loadShrinkwrap Completed in 5ms
16 silly install loadAllDepsIntoIdealTree
17 silly fetchPackageMetaData error for @composer-asset/kodus--media@file:vendor/foxy/composer-asset/kodus/media Invalid version: "dev-master"
18 timing stage:rollbackFailedOptional Completed in 0ms
19 timing stage:runTopLevelLifecycles Completed in 251ms
20 silly saveTree staging_project
21 verbose stack Error: Invalid version: "dev-master"
21 verbose stack at Object.fixVersionField (/usr/lib/node_modules/npm/node_modules/normalize-package-data/lib/fixer.js:191:13)
21 verbose stack at /usr/lib/node_modules/npm/node_modules/normalize-package-data/lib/normalize.js:32:38
21 verbose stack at Array.forEach (<anonymous>)
21 verbose stack at normalize (/usr/lib/node_modules/npm/node_modules/normalize-package-data/lib/normalize.js:31:15)
21 verbose stack at new Manifest (/usr/lib/node_modules/npm/node_modules/pacote/lib/finalize-manifest.js:121:3)
21 verbose stack at tarballedProps.then.props (/usr/lib/node_modules/npm/node_modules/pacote/lib/finalize-manifest.js:50:13)
21 verbose stack at tryCatcher (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/util.js:16:23)
21 verbose stack at Promise._settlePromiseFromHandler (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:512:31)
21 verbose stack at Promise._settlePromise (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:569:18)
21 verbose stack at Promise._settlePromiseCtx (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/promise.js:606:10)
21 verbose stack at Async._drainQueue (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:138:12)
21 verbose stack at Async._drainQueues (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:143:10)
21 verbose stack at Immediate.Async.drainQueues [as _onImmediate] (/usr/lib/node_modules/npm/node_modules/bluebird/js/release/async.js:17:14)
21 verbose stack at runCallback (timers.js:763:18)
21 verbose stack at tryOnImmediate (timers.js:734:5)
21 verbose stack at processImmediate (timers.js:716:5)
22 verbose cwd /mnt/c/workspace/test/staging_project
23 verbose Linux 4.4.0-17134-Microsoft
24 verbose argv "/usr/bin/node" "/usr/bin/npm" "install"
25 verbose node v9.11.2
26 verbose npm v6.3.0
27 error Invalid version: "dev-master"
28 verbose exit [ 1, true ]
I am just trying it out, so for now, I've manually listed two packages that have package
files via configuration in my project's composer.json
:
"config": {
"foxy": {
"enable-packages": {
"kodus/media": true,
"kodus/media-admin": true
}
}
}
Both of these packages are on unable dev-branches, both named 1.0.0
.
The package.json
files in those two packages both list some "dependencies"
for some npm packages.
If understand correctly, the idea is Foxy will aggregate these to a collective package.json
for the project containing all the npm-dependencies of those two packages?
Any idea what I'm doing wrong?