I recently installed laravel-8 and trying to install Laravel Jetstream for authentication following their official documentation. It's returning the below error.
$ composer require laravel/jetstream
Using version ^1.6 for laravel/jetstream
./composer.json has been updated
Running composer update laravel/jetstream
Loading composer repositories with package information
Updating dependencies
Lock file operations: 9 installs, 0 updates, 0 removals
- Locking bacon/bacon-qr-code (2.0.3)
- Locking dasprid/enum (1.0.3)
- Locking jaybizzle/crawler-detect (v1.2.103)
- Locking jenssegers/agent (v2.6.4)
- Locking laravel/fortify (v1.7.2)
- Locking laravel/jetstream (v1.6.3)
- Locking mobiledetect/mobiledetectlib (2.8.34)
- Locking paragonie/constant_time_encoding (v2.4.0)
- Locking pragmarx/google2fa (8.0.0)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 9 installs, 0 updates, 0 removals
- Downloading paragonie/constant_time_encoding (v2.4.0)
0/1 [>---------------------------] 0%
1/1 [============================] 100% - Installing dasprid/enum (1.0.3): Extracting archive
- Installing bacon/bacon-qr-code (2.0.3): Extracting archive
- Installing jaybizzle/crawler-detect (v1.2.103): Extracting archive
Install of jaybizzle/crawler-detect failed
- Installing paragonie/constant_time_encoding (v2.4.0): Extracting archive
- Installing pragmarx/google2fa (8.0.0): Extracting archive
- Installing laravel/fortify (v1.7.2): Extracting archive
- Installing mobiledetect/mobiledetectlib (2.8.34): Extracting archive
- Installing jenssegers/agent (v2.6.4): Extracting archive
- Installing laravel/jetstream (v1.6.3): Extracting archive
0 [>---------------------------] 0 [>---------------------------]
Installation failed, reverting ./composer.json and ./composer.lock to their original content.
[RuntimeException]
Could not delete C:\wamp\www\earnday/vendor/composer/18d01bbf\JayBizzle-Crawler-Detect-3efa286\src\Fixtures\Crawlers.php:
This can be due to an antivirus or the Windows Search Indexer locking the file while they are analyzed
What's the possible fix?
Related
There was a problem in php-http/discovery which should be fixed in 1.15.1 and composer 2.5.3
Still I can reproduce an infinite loop with the following (more or less) boiled down composer.json:
{
"name": "contao/managed-edition",
"type": "project",
"description": "Contao Open Source CMS - Bug Repro",
"license": "LGPL-3.0-or-later",
"require": {
"php": "^8.1",
"contao/conflicts": "*#dev",
"contao/manager-bundle": "4.13.*",
"imi/composer-scripts-contao": "^1.0",
"symfony/http-client": "*"
},
"extra": {
"contao-component-dir": "assets"
},
"config": {
"allow-plugins": {
"contao-components/installer": true,
"contao-community-alliance/composer-plugin": true,
"contao/manager-plugin": true,
"php-http/discovery": true
}
}
}
$ composer install
No composer.lock file present. Updating dependencies to latest instead of installing from lock file. See https://getcomposer.org/install for more information.
Loading composer repositories with package information
Updating dependencies
Lock file operations: 126 installs, 0 updates, 0 removals
- Locking ausi/slug-generator (v1.1.1)
- Locking bacon/bacon-qr-code (2.0.8)
- Locking beberlei/assert (v3.3.2)
- Locking clue/stream-filter (v1.6.0)
- Locking composer/ca-bundle (1.3.5)
- Locking contao-components/ace (1.15.0)
- Locking contao-components/chosen (1.2.5)
- Locking contao-components/colorbox (1.6.6)
- Locking contao-components/colorpicker (1.5.2)
- Locking contao-components/contao (9.3.2)
- Locking contao-components/datepicker (2.3.2)
- Locking contao-components/dropzone (5.9.3)
- Locking contao-components/installer (1.4.1)
- Locking contao-components/jquery (3.6.3)
- Locking contao-components/jquery-ui (1.13.2)
- Locking contao-components/mediabox (1.5.5)
- Locking contao-components/mootools (1.6.0.7)
- Locking contao-components/simplemodal (2.1.1)
- Locking contao-components/swipe (2.2.0)
- Locking contao-components/tablesort (4.0.1)
- Locking contao-components/tablesorter (2.31.3)
- Locking contao-components/tinymce4 (5.10.7)
- Locking contao/conflicts (dev-main 2d8ba56)
- Locking contao/core-bundle (4.13.15)
- Locking contao/image (1.1.2)
- Locking contao/imagine-svg (1.0.3)
- Locking contao/installation-bundle (4.13.15)
- Locking contao/manager-bundle (4.13.15)
- Locking contao/manager-plugin (2.12.0)
- Locking dasprid/enum (1.0.3)
- Locking dflydev/dot-access-data (v3.0.2)
- Locking doctrine/annotations (1.14.3)
- Locking doctrine/cache (2.2.0)
- Locking doctrine/collections (1.8.0)
- Locking doctrine/common (3.4.3)
- Locking doctrine/dbal (3.6.0)
- Locking doctrine/deprecations (v1.0.0)
- Locking doctrine/doctrine-bundle (2.8.3)
- Locking doctrine/event-manager (1.2.0)
- Locking doctrine/inflector (2.0.6)
- Locking doctrine/instantiator (1.5.0)
- Locking doctrine/lexer (2.1.0)
- Locking doctrine/orm (2.14.1)
- Locking doctrine/persistence (2.5.7)
- Locking doctrine/sql-formatter (1.1.3)
- Locking dragonmantank/cron-expression (v2.3.1)
- Locking friendsofphp/proxy-manager-lts (v1.0.14)
- Locking friendsofsymfony/http-cache (2.15.0)
- Locking friendsofsymfony/http-cache-bundle (2.14.0)
- Locking imagine/imagine (1.3.3)
- Locking imi/composer-scripts-contao (1.0.1)
- Locking imi/database-helper (0.3.1)
- Locking knplabs/knp-menu (v3.3.0)
- Locking knplabs/knp-menu-bundle (v3.2.0)
- Locking knplabs/knp-time-bundle (v1.20.0)
- Locking laminas/laminas-code (4.8.0)
- Locking lcobucci/clock (2.3.0)
- Locking lcobucci/jwt (4.1.5)
- Locking league/commonmark (2.3.8)
- Locking league/config (v1.2.0)
- Locking league/flysystem (3.12.2)
- Locking league/flysystem-bundle (2.4.0)
- Locking league/mime-type-detection (1.11.0)
- Locking matthiasmullie/minify (1.3.70)
- Locking matthiasmullie/path-converter (1.1.3)
- Locking monolog/monolog (2.9.1)
- Locking nelmio/cors-bundle (2.2.0)
- Locking nelmio/security-bundle (v2.12.0)
- Locking nette/schema (v1.2.3)
- Locking nette/utils (v4.0.0)
- Locking nikic/php-parser (v4.15.3)
- Locking nyholm/psr7 (1.5.1)
- Locking paragonie/constant_time_encoding (v2.6.3)
- Locking paragonie/random_compat (v9.99.100)
- Locking php-http/client-common (2.6.0)
- Locking php-http/discovery (1.15.1)
- Locking php-http/httplug (2.3.0)
- Locking php-http/message (1.13.0)
- Locking php-http/message-factory (v1.0.2)
- Locking php-http/promise (1.1.0)
- Locking phpspec/php-diff (v1.1.3)
- Locking psr/cache (2.0.0)
- Locking psr/clock (1.0.0)
- Locking psr/container (1.1.2)
- Locking psr/event-dispatcher (1.0.0)
- Locking psr/http-client (1.0.1)
- Locking psr/http-factory (1.0.1)
- Locking psr/http-message (1.0.1)
- Locking psr/link (1.1.1)
- Locking psr/log (1.1.4)
- Locking scheb/2fa-backup-code (v5.13.2)
- Locking scheb/2fa-bundle (v5.13.2)
- Locking scheb/2fa-trusted-device (v5.13.2)
- Locking scrivo/highlight.php (v9.18.1.10)
- Locking scssphp/scssphp (v1.11.0)
- Locking sensiolabs/ansi-to-html (v1.2.1)
- Locking simplepie/simplepie (1.8.0)
- Locking spatie/schema-org (3.13.0)
- Locking spomky-labs/otphp (v10.0.3)
- Locking stella-maris/clock (0.1.7)
- Locking symfony-cmf/routing (2.3.4)
- Locking symfony-cmf/routing-bundle (2.5.1)
- Locking symfony/contracts (v2.5.2)
- Locking symfony/monolog-bundle (v3.8.0)
- Locking symfony/polyfill-ctype (v1.27.0)
- Locking symfony/polyfill-intl-grapheme (v1.27.0)
- Locking symfony/polyfill-intl-icu (v1.27.0)
- Locking symfony/polyfill-intl-idn (v1.27.0)
- Locking symfony/polyfill-intl-normalizer (v1.27.0)
- Locking symfony/polyfill-mbstring (v1.27.0)
- Locking symfony/polyfill-php72 (v1.27.0)
- Locking symfony/polyfill-php73 (v1.27.0)
- Locking symfony/polyfill-php80 (v1.27.0)
- Locking symfony/polyfill-php81 (v1.27.0)
- Locking symfony/polyfill-uuid (v1.27.0)
- Locking symfony/symfony (v5.4.20)
- Locking terminal42/escargot (1.5.1)
- Locking terminal42/service-annotation-bundle (1.1.4)
- Locking thecodingmachine/safe (v2.4.0)
- Locking toflar/psr6-symfony-http-cache-store (3.0.1)
- Locking twig/extra-bundle (v3.5.1)
- Locking twig/twig (v3.5.1)
- Locking ua-parser/uap-php (v3.9.14)
- Locking webignition/disallowed-character-terminated-string (2.0)
- Locking webignition/robots-txt-file (3.0)
- Locking wikimedia/less.php (1.8.2)
Writing lock file
Installing dependencies from lock file (including require-dev)
Package operations: 126 installs, 0 updates, 0 removals
- Installing contao-components/installer (1.4.1): Extracting archive
- Installing php-http/discovery (1.15.1): Extracting archive
- Installing symfony/polyfill-mbstring (v1.27.0): Extracting archive
- Installing symfony/polyfill-php73 (v1.27.0): Extracting archive
- Installing symfony/polyfill-ctype (v1.27.0): Extracting archive
- Installing twig/twig (v3.5.1): Extracting archive
- Installing symfony/polyfill-uuid (v1.27.0): Extracting archive
- Installing symfony/polyfill-php81 (v1.27.0): Extracting archive
- Installing symfony/polyfill-php80 (v1.27.0): Extracting archive
- Installing symfony/polyfill-intl-normalizer (v1.27.0): Extracting archive
- Installing symfony/polyfill-php72 (v1.27.0): Extracting archive
- Installing symfony/polyfill-intl-idn (v1.27.0): Extracting archive
- Installing symfony/polyfill-intl-icu (v1.27.0): Extracting archive
- Installing symfony/polyfill-intl-grapheme (v1.27.0): Extracting archive
- Installing psr/event-dispatcher (1.0.0): Extracting archive
- Installing psr/container (1.1.2): Extracting archive
- Installing psr/cache (2.0.0): Extracting archive
- Installing symfony/contracts (v2.5.2): Extracting archive
- Installing psr/log (1.1.4): Extracting archive
- Installing psr/link (1.1.1): Extracting archive
- Installing symfony/symfony (v5.4.20): Extracting archive
- Installing contao/manager-plugin (2.12.0): Extracting archive
- Installing ausi/slug-generator (v1.1.1): Extracting archive
- Installing dasprid/enum (1.0.3): Extracting archive
- Installing bacon/bacon-qr-code (2.0.8): Extracting archive
- Installing contao-components/ace (1.15.0): Extracting archive
- Installing contao-components/chosen (1.2.5): Extracting archive
- Installing contao-components/colorbox (1.6.6): Extracting archive
- Installing contao-components/colorpicker (1.5.2): Extracting archive
- Installing contao-components/contao (9.3.2): Extracting archive
- Installing contao-components/datepicker (2.3.2): Extracting archive
- Installing contao-components/dropzone (5.9.3): Extracting archive
- Installing contao-components/jquery (3.6.3): Extracting archive
- Installing contao-components/jquery-ui (1.13.2): Extracting archive
- Installing contao-components/mediabox (1.5.5): Extracting archive
- Installing contao-components/mootools (1.6.0.7): Extracting archive
- Installing contao-components/simplemodal (2.1.1): Extracting archive
- Installing contao-components/swipe (2.2.0): Extracting archive
- Installing contao-components/tablesort (4.0.1): Extracting archive
- Installing contao-components/tablesorter (2.31.3): Extracting archive
- Installing contao-components/tinymce4 (5.10.7): Extracting archive
- Installing contao/conflicts (dev-main 2d8ba56)
- Installing laminas/laminas-code (4.8.0): Extracting archive
- Installing friendsofphp/proxy-manager-lts (v1.0.14): Extracting archive
- Installing doctrine/deprecations (v1.0.0): Extracting archive
- Installing doctrine/event-manager (1.2.0): Extracting archive
- Installing doctrine/collections (1.8.0): Extracting archive
- Installing doctrine/cache (2.2.0): Extracting archive
- Installing doctrine/persistence (2.5.7): Extracting archive
- Installing imagine/imagine (1.3.3): Extracting archive
- Installing contao/image (1.1.2): Extracting archive
- Installing contao/imagine-svg (1.0.3): Extracting archive
- Installing twig/extra-bundle (v3.5.1): Extracting archive
- Installing toflar/psr6-symfony-http-cache-store (3.0.1): Extracting archive
- Installing monolog/monolog (2.9.1): Extracting archive
- Installing symfony/monolog-bundle (v3.8.0): Extracting archive
- Installing composer/ca-bundle (1.3.5): Extracting archive
- Installing ua-parser/uap-php (v3.9.14): Extracting archive
- Installing paragonie/random_compat (v9.99.100): Extracting archive
- Installing nelmio/security-bundle (v2.12.0): Extracting archive
- Installing nelmio/cors-bundle (2.2.0): Extracting archive
- Installing psr/http-message (1.0.1): Extracting archive
- Installing php-http/message-factory (v1.0.2): Extracting archive
- Installing clue/stream-filter (v1.6.0): Extracting archive
- Installing php-http/message (1.13.0): Extracting archive
- Installing psr/http-factory (1.0.1): Extracting archive
- Installing psr/http-client (1.0.1): Extracting archive
- Installing php-http/promise (1.1.0): Extracting archive
- Installing php-http/httplug (2.3.0): Extracting archive
- Installing php-http/client-common (2.6.0): Extracting archive
- Installing friendsofsymfony/http-cache (2.15.0): Extracting archive
- Installing friendsofsymfony/http-cache-bundle (2.14.0): Extracting archive
- Installing doctrine/sql-formatter (1.1.3): Extracting archive
- Installing doctrine/dbal (3.6.0): Extracting archive
- Installing doctrine/doctrine-bundle (2.8.3): Extracting archive
- Installing sensiolabs/ansi-to-html (v1.2.1): Extracting archive
- Installing wikimedia/less.php (1.8.2): Extracting archive
- Installing webignition/disallowed-character-terminated-string (2.0): Extracting archive
- Installing webignition/robots-txt-file (3.0): Extracting archive
- Installing doctrine/lexer (2.1.0): Extracting archive
- Installing doctrine/annotations (1.14.3): Extracting archive
- Installing terminal42/service-annotation-bundle (1.1.4): Extracting archive
- Installing nyholm/psr7 (1.5.1): Extracting archive
- Installing terminal42/escargot (1.5.1): Extracting archive
- Installing symfony-cmf/routing (2.3.4): Extracting archive
- Installing symfony-cmf/routing-bundle (2.5.1): Extracting archive
- Installing thecodingmachine/safe (v2.4.0): Extracting archive
- Installing paragonie/constant_time_encoding (v2.6.3): Extracting archive
- Installing beberlei/assert (v3.3.2): Extracting archive
- Installing spomky-labs/otphp (v10.0.3): Extracting archive
- Installing spatie/schema-org (3.13.0): Extracting archive
- Installing simplepie/simplepie (1.8.0): Extracting archive
- Installing scssphp/scssphp (v1.11.0): Extracting archive
- Installing scrivo/highlight.php (v9.18.1.10): Extracting archive
- Installing scheb/2fa-bundle (v5.13.2): Extracting archive
- Installing psr/clock (1.0.0): Extracting archive
- Installing stella-maris/clock (0.1.7): Extracting archive
- Installing lcobucci/clock (2.3.0): Extracting archive
- Installing lcobucci/jwt (4.1.5): Extracting archive
- Installing scheb/2fa-trusted-device (v5.13.2): Extracting archive
- Installing scheb/2fa-backup-code (v5.13.2): Extracting archive
- Installing phpspec/php-diff (v1.1.3): Extracting archive
- Installing nikic/php-parser (v4.15.3): Extracting archive
- Installing matthiasmullie/path-converter (1.1.3): Extracting archive
- Installing matthiasmullie/minify (1.3.70): Extracting archive
- Installing league/mime-type-detection (1.11.0): Extracting archive
- Installing league/flysystem (3.12.2): Extracting archive
- Installing league/flysystem-bundle (2.4.0): Extracting archive
- Installing nette/utils (v4.0.0): Extracting archive
- Installing nette/schema (v1.2.3): Extracting archive
- Installing dflydev/dot-access-data (v3.0.2): Extracting archive
- Installing league/config (v1.2.0): Extracting archive
- Installing league/commonmark (2.3.8): Extracting archive
- Installing knplabs/knp-time-bundle (v1.20.0): Extracting archive
- Installing knplabs/knp-menu (v3.3.0): Extracting archive
- Installing knplabs/knp-menu-bundle (v3.2.0): Extracting archive
- Installing dragonmantank/cron-expression (v2.3.1): Extracting archive
- Installing doctrine/instantiator (1.5.0): Extracting archive
- Installing doctrine/inflector (2.0.6): Extracting archive
- Installing doctrine/common (3.4.3): Extracting archive
- Installing doctrine/orm (2.14.1): Extracting archive
- Installing contao/core-bundle (4.13.15): Extracting archive
- Installing contao/installation-bundle (4.13.15): Extracting archive
- Installing contao/manager-bundle (4.13.15): Extracting archive
- Installing imi/database-helper (0.3.1): Extracting archive
- Installing imi/composer-scripts-contao (1.0.1): Extracting archive
29 package suggestions were added by new dependencies, use `composer suggest` to see details.
Generating autoload files
49 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
Loading composer repositories with package information
Updating dependencies
Nothing to modify in lock file
Installing dependencies from lock file (including require-dev)
Nothing to install, update or remove
Generating autoload files
49 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
Loading composer repositories with package information
Updating dependencies
Nothing to modify in lock file
Installing dependencies from lock file (including require-dev)
Nothing to install, update or remove
Generating autoload files
49 packages you are using are looking for funding.
Use the `composer fund` command to find out more!
Loading composer repositories with package information
$ composer --version
Composer version 2.5.3 2023-02-10 13:23:52
The imi/composer-scripts-contao module does (I believe) not do anything special concerning composer plugins.
If I remove our (own) module imi/composer-scripts-contao or disable the plugin php-http/discovery it works.
Of course I could do one of both options (we even want to replace that own module), but I would like to understand the root cause of this problem and if the php-http/discovery still causes problems here.
This is a bug, fixed by https://github.com/php-http/discovery/pull/219
Next time, please open a new issue on the affected repository 🙏
Is there any way to know what packages will/will not be autoloaded when using the --no-dev flag?
I have inherited some code that uses composer and Im unsure what packages are included in the production build and what are only included in the dev build.
Since doing composer dump-autoload --no-dev gives me errors regarding missing classes I suspect that some packages are flagged as dev-only when they should not and I'm trying to track those down.
I havent found anything in the composer docs to help me doing this.
The easiest way to check which packages are dev-only is to run composer install (this will install all dependencies, including dev-only) and then composer install --no-dev (this will remove dev-only dependencies). Last command will give you list of removed dependencies - these are packages not available in production builds, you should not rely on them (or move them to require section in your composer.json).
Example:
$ composer install
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Package operations: 56 installs, 0 updates, 0 removals
- Installing yiisoft/yii2-composer (2.0.7): Loading from cache
- Installing bower-asset/jquery (3.3.1): Loading from cache
- Installing bower-asset/bootstrap (v3.4.1): Loading from cache
- Installing bower-asset/inputmask (3.3.11): Loading from cache
- Installing bower-asset/punycode (v1.3.2): Loading from cache
- Installing bower-asset/yii2-pjax (2.0.7.1): Loading from cache
- Installing cebe/markdown (1.2.1): Loading from cache
- Installing ezyang/htmlpurifier (v4.10.0): Loading from cache
- Installing yiisoft/yii2 (2.0.17): Loading from cache
- Installing swiftmailer/swiftmailer (v5.4.12): Loading from cache
- Installing yiisoft/yii2-swiftmailer (2.0.7): Loading from cache
- Installing symfony/polyfill-ctype (v1.11.0): Loading from cache
- Installing symfony/yaml (v2.8.49): Loading from cache
- Installing symfony/finder (v2.8.49): Loading from cache
- Installing symfony/event-dispatcher (v2.8.49): Loading from cache
- Installing symfony/polyfill-mbstring (v1.11.0): Loading from cache
- Installing symfony/dom-crawler (v2.8.49): Loading from cache
- Installing symfony/css-selector (v2.8.49): Loading from cache
- Installing psr/log (1.1.0): Loading from cache
- Installing symfony/debug (v2.8.49): Loading from cache
- Installing symfony/console (v2.8.49): Loading from cache
- Installing symfony/browser-kit (v2.8.49): Loading from cache
- Installing ralouphie/getallheaders (2.0.5): Loading from cache
- Installing psr/http-message (1.0.1): Loading from cache
- Installing guzzlehttp/psr7 (1.5.2): Loading from cache
- Installing sebastian/recursion-context (1.0.5): Loading from cache
- Installing sebastian/exporter (1.2.2): Loading from cache
- Installing phpunit/php-text-template (1.2.1): Loading from cache
- Installing doctrine/instantiator (1.0.5): Loading from cache
- Installing phpunit/phpunit-mock-objects (2.3.8): Loading from cache
- Installing codeception/stub (1.0.4): Loading from cache
- Installing sebastian/diff (1.4.3): Loading from cache
- Installing sebastian/comparator (1.2.4): Loading from cache
- Installing sebastian/version (1.0.6): Loading from cache
- Installing sebastian/global-state (1.1.1): Loading from cache
- Installing sebastian/environment (1.3.8): Loading from cache
- Installing phpunit/php-timer (1.0.9): Loading from cache
- Installing phpunit/php-file-iterator (1.4.5): Loading from cache
- Installing phpunit/php-token-stream (1.4.12): Loading from cache
- Installing phpunit/php-code-coverage (2.2.4): Loading from cache
- Installing phpdocumentor/reflection-docblock (2.0.5): Loading from cache
- Installing phpspec/prophecy (1.8.0): Loading from cache
- Installing phpunit/phpunit (4.8.36): Loading from cache
- Installing codeception/phpunit-wrapper (6.0.10): Loading from cache
- Installing behat/gherkin (v4.6.0): Loading from cache
- Installing codeception/base (2.4.1): Loading from cache
- Installing myclabs/deep-copy (1.6.1): Loading from cache
- Installing codeception/specify (0.4.6): Loading from cache
- Installing codeception/verify (0.3.3): Loading from cache
- Installing yiisoft/yii2-bootstrap (2.0.9): Loading from cache
- Installing yiisoft/yii2-debug (2.0.14): Loading from cache
- Installing fzaninotto/faker (v1.8.0): Loading from cache
- Installing yiisoft/yii2-faker (2.0.4): Loading from cache
- Installing phpspec/php-diff (v1.1.0): Loading from cache
- Installing bower-asset/typeahead.js (v0.11.1): Loading from cache
- Installing yiisoft/yii2-gii (2.0.8): Loading from cache
Generating autoload files
And then list of dev-only dependencies:
$ composer install --no-dev
Loading composer repositories with package information
Installing dependencies from lock file
Package operations: 0 installs, 0 updates, 44 removals
- Removing yiisoft/yii2-gii (2.0.8)
- Removing yiisoft/yii2-faker (2.0.4)
- Removing yiisoft/yii2-debug (2.0.14)
- Removing symfony/yaml (v2.8.49)
- Removing symfony/polyfill-mbstring (v1.11.0)
- Removing symfony/polyfill-ctype (v1.11.0)
- Removing symfony/finder (v2.8.49)
- Removing symfony/event-dispatcher (v2.8.49)
- Removing symfony/dom-crawler (v2.8.49)
- Removing symfony/debug (v2.8.49)
- Removing symfony/css-selector (v2.8.49)
- Removing symfony/console (v2.8.49)
- Removing symfony/browser-kit (v2.8.49)
- Removing sebastian/version (1.0.6)
- Removing sebastian/recursion-context (1.0.5)
- Removing sebastian/global-state (1.1.1)
- Removing sebastian/exporter (1.2.2)
- Removing sebastian/environment (1.3.8)
- Removing sebastian/diff (1.4.3)
- Removing sebastian/comparator (1.2.4)
- Removing ralouphie/getallheaders (2.0.5)
- Removing psr/log (1.1.0)
- Removing psr/http-message (1.0.1)
- Removing phpunit/phpunit-mock-objects (2.3.8)
- Removing phpunit/phpunit (4.8.36)
- Removing phpunit/php-token-stream (1.4.12)
- Removing phpunit/php-timer (1.0.9)
- Removing phpunit/php-text-template (1.2.1)
- Removing phpunit/php-file-iterator (1.4.5)
- Removing phpunit/php-code-coverage (2.2.4)
- Removing phpspec/prophecy (1.8.0)
- Removing phpspec/php-diff (v1.1.0)
- Removing phpdocumentor/reflection-docblock (2.0.5)
- Removing myclabs/deep-copy (1.6.1)
- Removing guzzlehttp/psr7 (1.5.2)
- Removing fzaninotto/faker (v1.8.0)
- Removing doctrine/instantiator (1.0.5)
- Removing codeception/verify (0.3.3)
- Removing codeception/stub (1.0.4)
- Removing codeception/specify (0.4.6)
- Removing codeception/phpunit-wrapper (6.0.10)
- Removing codeception/base (2.4.1)
- Removing bower-asset/typeahead.js (v0.11.1)
- Removing behat/gherkin (v4.6.0)
Generating autoload files
There is also a maglnet/composer-require-checker which may be useful for detecting usage of libraries not listed in require section.
Basically, any package (and its dependencies) in require-dev section of your composer.json file will not be autoloaded when you use composer dump-autoload --no-dev. Sadly, I don't think there's a command to show those packages together with their dependencies as a single list.
What you can do is try moving each of the packages from require-dev section to require, reruning composer update and composer dump-autoload --no-dev to see when your error disappears.
I just discovered that you can show all root packages using composer show -s:
name : roots/bedrock
descrip. : WordPress boilerplate with modern development tools, easier configuration, and an improved folder structure
keywords : bedrock, roots, wordpress, stack, composer, vagrant, wp
versions : * dev-update-and-apply-aq-changes
type : project
license : MIT License (MIT) (OSI approved) https://spdx.org/licenses/MIT.html#licenseText
homepage : https://roots.io/bedrock/
source : [] 412b5d6779300e49762ed2402d0f87ca50475f2f
dist : [] 412b5d6779300e49762ed2402d0f87ca50475f2f
path :
names : roots/bedrock
support
issues : https://github.com/roots/bedrock/issues
forum : https://discourse.roots.io/category/bedrock
requires
php >=7.0
composer/installers ^1.11
oscarotero/env ^1.2.0
roots/wordpress 5.7.2
roots/wp-password-bcrypt 1.0.0
roots/wp-config 1.0.0
advanced-custom-fields/advanced-custom-fields-pro *
wpackagist-plugin/wordpress-seo ^16.1
requires (dev)
squizlabs/php_codesniffer ^3.0.2
dealerdirect/phpcodesniffer-composer-installer *
wp-coding-standards/wpcs *
wpackagist-plugin/query-monitor ^3.7
roave/security-advisories dev-master
And then you can cut out the requires (dev) section using composer show -s | sed -n '/requires (dev)$/,/^$/p'
requires (dev)
squizlabs/php_codesniffer ^3.0.2
dealerdirect/phpcodesniffer-composer-installer *
wp-coding-standards/wpcs *
wpackagist-plugin/query-monitor ^3.7
roave/security-advisories dev-master
And then you can get rid of the title using composer show -s | sed -n '/requires (dev)$/,/^$/p' | grep -v 'requires (dev)'
squizlabs/php_codesniffer ^3.0.2
dealerdirect/phpcodesniffer-composer-installer *
wp-coding-standards/wpcs *
wpackagist-plugin/query-monitor ^3.7
roave/security-advisories dev-master
And then you can get rid of the version using composer show -s | sed -n '/requires (dev)$/,/^$/p' | grep -v 'requires (dev)' | cut -d ' ' -f1
squizlabs/php_codesniffer
dealerdirect/phpcodesniffer-composer-installer
wp-coding-standards/wpcs
wpackagist-plugin/query-monitor
roave/security-advisories
i'm working already with symfony 3, I've create a lot of project with it, so now i'm trying to create a project with symfony 4, but i can't when i type this command :
composer create-project symfony/skeleton my-project-symf-4
the project is created successfully, but the problem that is created with this version 3.4 instead of 4.2,
Installing symfony/skeleton (v3.4.22.1)
- Installing symfony/skeleton (v3.4.22.1): Downloading (100%)
Created project in my-project-symf-4
Loading composer repositories with package information
Installing dependencies (including require-dev) from lock file
Package operations: 22 installs, 0 updates, 0 removals
- Installing symfony/flex (v1.1.8): Downloading (100%)
Prefetching 21 packages
- Downloading (100%)
- Installing psr/cache (1.0.1): Loading from cache
- Installing psr/container (1.0.0): Loading from cache
- Installing psr/simple-cache (1.0.1): Loading from cache
- Installing symfony/polyfill-mbstring (v1.10.0): Loading from cache
- Installing psr/log (1.1.0): Loading from cache
- Installing symfony/debug (v3.4.22): Loading from cache
- Installing symfony/console (v3.4.22): Loading from cache
- Installing symfony/dotenv (v3.4.22): Loading from cache
- Installing symfony/routing (v3.4.22): Loading from cache
- Installing symfony/http-foundation (v3.4.22): Loading from cache
- Installing symfony/event-dispatcher (v3.4.22): Loading from cache
- Installing symfony/http-kernel (v3.4.22): Loading from cache
- Installing symfony/finder (v3.4.22): Loading from cache
- Installing symfony/filesystem (v3.4.22): Loading from cache
- Installing symfony/dependency-injection (v3.4.22): Loading from cache
- Installing symfony/config (v3.4.22): Loading from cache
- Installing symfony/class-loader (v3.4.22): Loading from cache
- Installing symfony/polyfill-apcu (v1.10.0): Loading from cache
- Installing symfony/cache (v3.4.22): Loading from cache
- Installing symfony/framework-bundle (v3.4.22): Loading from cache
- Installing symfony/yaml (v3.4.22): Loading from cache
Generating autoload files
So as you can see the composer load all packages from cache.
I've try to clear composer cache like this:
$ composer clearcache
but without result, the problem still exist.
My PHP Version is 7.3.1
Can anyone help me to resolve that problem?
Try to pass the symfony version (4.2 for example) like that:
composer create-project symfony/skeleton:4.2 my-project-symf-4
Hope this helps!
If you installed symfony CLI in your system then you just run the below command with specifying version number
For Example to create a Symfony project with 4.4 version run following command
symfony new my_project_name --version=4.4
I'm using the acelaya/zf2-acqrcode package (v0.2.0) It requires "endroid/qrcode": ">=1.2.0", (meaning everything higher than or equal to 1.2.0)
Currently the latest version of the "endroid/qrcode" package = v3.2.12
The acelaya/zf2-acqrcode package (v0.2.0) uses a function that doesn't exist anymore in endroid/qrcode versions > 1.9.3
Is there any way I can tell composer not to install a version of the endroid/qrcode package higher than 1.9.3?
Yes you can restrict the package versions by using the ~ operator in composer.json. More Information on that can be found Here
Hope this helps.
Use the following to lock the endroid/qrcode dependency to 1.9.3. Sub dependencies will adhere to this and honour the fact you've locked acelaya/zf2-acqrcode.
Note: this will only fail when another dependency requires >1.9.3 of endroid/qrcode
{
"require": {
"endroid/qrcode": "1.9.3",
"acelaya/zf2-acqrcode": "^1.0"
}
}
Run the command following command:
/path/to/composer.phar require endroid/qrcode:1.9.3
Here's the output of the above required dependencies:
$ composer install
Loading composer repositories with package information Updating dependencies (including require-dev) Package operations: 18 installs, 0 updates, 0 removals
- Installing zendframework/zend-stdlib (3.2.0): Loading from cache
- Installing zendframework/zend-loader (2.6.0): Loading from cache
- Installing zendframework/zend-eventmanager (3.2.1): Loading from cache
- Installing zendframework/zend-view (2.10.0): Loading from cache
- Installing psr/container (1.0.0): Loading from cache
- Installing container-interop/container-interop (1.2.0): Loading from cache
- Installing zendframework/zend-servicemanager (3.3.2): Loading from cache
- Installing zendframework/zend-validator (2.10.2): Loading from cache
- Installing zendframework/zend-escaper (2.6.0): Loading from cache
- Installing zendframework/zend-uri (2.6.1): Loading from cache
- Installing zendframework/zend-http (2.8.0): Loading from cache
- Installing zendframework/zend-router (3.0.2): Loading from cache
- Installing zendframework/zend-config (3.2.0): Loading from cache
- Installing zendframework/zend-modulemanager (2.8.2): Loading from cache
- Installing zendframework/zend-mvc (3.1.1): Loading from cache
- Installing symfony/options-resolver (v3.4.11): Loading from cache
- Installing endroid/qrcode (1.9.3): Loading from cache
- Installing acelaya/zf2-acqrcode (v1.0.0): Loading from cache
Installing mailgun bundle for Symfony breaks down "bin/console" command
How and where to get working mailgun bundle for Symfony 4?
$ composer require cspoo/swiftmailer-mailgun-bundle:*
./composer.json has been updated
Loading composer repositories with package information
Updating dependencies (including require-dev)
Package operations: 11 installs, 0 updates, 0 removals
- Installing php-http/discovery (1.4.0): Loading from cache
- Installing psr/http-message (1.0.1): Loading from cache
- Installing php-http/message-factory (v1.0.2): Loading from cache
- Installing clue/stream-filter (v1.4.0): Loading from cache
- Installing php-http/message (1.6.0): Loading from cache
- Installing php-http/promise (v1.0.0): Loading from cache
- Installing php-http/httplug (v1.1.0): Loading from cache
- Installing php-http/client-common (1.7.0): Loading from cache
- Installing php-http/multipart-stream-builder (1.0.0): Loading from cache
- Installing mailgun/mailgun-php (2.4.1): Loading from cache
- Installing cspoo/swiftmailer-mailgun-bundle (0.1.2): Downloading (100%)
Writing lock file
Generating autoload files
ocramius/package-versions: Generating version class...
ocramius/package-versions: ...done generating version class
Symfony operations: 2 recipes (9b46b734d14be831804cdcde063bdadf)
- WARNING mailgun/mailgun-php (>=2.3): From github.com/symfony/recipes-contrib:master
The recipe for this package comes from the "contrib" repository, which is open to community contributions.
Review the recipe at https://github.com/symfony/recipes-contrib/tree/master/mailgun/mailgun-php/2.3
Do you want to execute this recipe?
[y] Yes
[n] No
[a] Yes for all packages, only for the current installation session
[p] Yes permanently, never ask again for this project
(defaults to n): y
- Configuring mailgun/mailgun-php (>=2.3): From github.com/symfony/recipes-contrib:master
- Configuring cspoo/swiftmailer-mailgun-bundle (>=0.1.2): From auto-generated recipe
Executing script cache:clear [KO]
[KO]
Script cache:clear returned with error code 1
!!
!! In ArrayNode.php line 238:
!!
!! The child node "key" at path "mailgun" must be configured.
!!
!!
!!
Installation failed, reverting ./composer.json to its original content.