Questions tagged [composer]
Use it for questions about the PHP application library dependency manager (Composer).
607
questions
0
votes
0
answers
873
views
Issues after updating Composer 2
I have been using drupal for over a month now. I am unable to install modules properly because of the composer 2 updating issues.
So far I have made the following changes while updating composer 2
&...
0
votes
1
answer
4k
views
Locked to version problem when upgrading
Every time I run the composer command to upgrade Drupal 8.9.16 to Drupal 9, it notifies me that there is a problem with a module.
For example, I run:
composer require drupal/core --with-all-...
0
votes
1
answer
181
views
How to update a module in production?
I am using git to deploy my composer.lock to production. Contrib is not part of my git repo. Therefore, in production I then run composer install to add contrib to production.
What happens when I ...
0
votes
0
answers
158
views
Module update with composer, updates module but not really
I am updating modules on my drupal site and I am using the composer like this:
composer require 'drupal/module'
The output I get from composer looks like everything is working fine but when I go to ...
0
votes
1
answer
1k
views
upgrade_status - unexpected error about PHP version
I'm doing preparatory work for upgrading a site from D8 to D9...
The Drupal dev site (macOS 10.14.6 served with Laravel Vagrant) is running PHP 7.3.28, both on command line and php-fpm, and I'm seeing ...
11
votes
1
answer
2k
views
How do I apply patches from a merge request? [duplicate]
I used the patch #48 of Views exposed sort identifiers are not configurable. I need to update the core, and apply the latest rebased version of that.
However, the issue hasn't be marked Fixed, and I ...
1
vote
1
answer
816
views
How do I avoid overwriting the .htaccess file when I use the Compose command?
On my new Drupal 9 website, I customized the .htaccess file and the robots.txt file
I don't want its files to be overwritten when updating with Composer.
I added the lines below in my composer.json ...
0
votes
0
answers
197
views
Composer memory limit error on update ( AWS Lightsail)
I'm running an AWS lightsail server for a Drupal 8 qa site. I'm getting an out of memory error when running update. I created a new server with 2GB of memory, and was able to run updates for a few ...
0
votes
0
answers
33
views
Update installs a beta version [duplicate]
I'm trying to update Drupal from 9.1.8 to 9.1.9. However, running a composer update jumps to 9.2-beta2. I'm not sure how to fix it so that it sticks to the recommended version.
My composer.json has ...
1
vote
0
answers
152
views
Drush can't find commands inside vagrant VM
I have a new install of Drupal 9.1.8, with drush 10.5 installed through composer inside a Vagrant VM.
But drush list gives:
Available commands:
help Displays help for a command
list Lists ...
4
votes
1
answer
2k
views
What is the best practice for handling abandoned packages required by the drupal core?
When I run composer update on a Drupal 9 website, I get this warning:
Package doctrine/reflection is abandoned, you should avoid using it. Use roave/better-reflection instead.
A similar question has ...
1
vote
1
answer
364
views
Trait 'Drupal\entity\Form\EntityDuplicateFormTrait' not found, while setting up existing site
I'm in the process of attempting to setup a development environment for a Drupal site that's been provided by a vendor. From what I've been told, the sites been setup and running on our UAT (Ubuntu) ...
2
votes
1
answer
177
views
How is composer including a dependent module?
I have a composer managed Drupal project based on drupal/recommended-project.
I'm installing a contrib module, domain_group, and I'm seeing that composer is auto-including a required dependency, even ...
0
votes
0
answers
171
views
Composer require drupal/social_auth_google - Your requirements could not be resolved to an installable set of packages
Previously I got an error with the command
composer require "drupal/social_auth_google:^2.0"
So I tried;
composer require "drupal/social_api:2.x-dev" "drupal/social_auth:2.x-...
0
votes
1
answer
130
views
How to override version of drupal-library (JavaScript library) included with composer merge-plugin?
I'm using Webform with the composer-merge plugin to bring in its libraries:
Relevant parts of my composer.json file:
"extra": {
"installer-paths": {
"...
0
votes
0
answers
76
views
Swiftmailer prevent composer updates
I have an issue with composer and Drupal 8.9.13. When I try to update Drupal, I always get the next error and I don't find a way to solve it:
#$> php -d memory_limit=-1 composer.phar update drupal/...
0
votes
1
answer
160
views
Installing a v8 module [duplicate]
If a contrib module's info.yml contains core: 8.x and not core_version_requirement: ^8.8 || ^9, how can a site be upgraded to Drupal 9 using composer?
composer update downloads modules in "...
0
votes
2
answers
749
views
Composer won't upgrade drupal/core-recommended
My composer.json is below
{ "name": "drupal/recommended-project&...
3
votes
2
answers
554
views
Installing Acquia BLT on an existing site
We have a working Drupal 9 installation (running within Docksal), which has pretty much the whole install living in docroot/ except for the config/ directory, which is a sibling of docroot/. This ...
0
votes
3
answers
2k
views
Stuck in my config import because of guzzlehttp/guzzle error
I am trying to import the config from another of my Drupal 9.1.4 projects with Composer / Drush (drush config-import from a folder source, all two websites on my local repository on Xampp), but a ...
-2
votes
1
answer
947
views
Issue installing module via composer. - "package is fixed"
I've installed Drupal via Composer as well as 2 other modules and everything seemed ok. But now I tried installing Nodeaccess and get the following error message in console:
Your requirements could ...
0
votes
0
answers
776
views
I cannot upgrade
I'm currently with Drupal 8.9.13 and trying to update to Drupal 9. When I try the below command it says Nothing to install or update.
composer update drupal/core-recommended --with-dependencies
When I ...
0
votes
1
answer
139
views
Is it possible to install Drush 9 without using Composer?
Is it somehow possible to install Drush 9 without using Composer?
0
votes
0
answers
168
views
Why do I get an error about the constant SODIUM_LIBRARY_VERSION not being found?
I'm on shared hosting, and I'm trying to install drupal 8 using composer. When I run composer create-project drupal/recommended-project:8.x-dev my_site_name_dir, I get this error.
constant(): Couldn'...
0
votes
0
answers
27
views
Demo Framework versioning issue
Is the Demo Framework project not compatible with Composer 2.0? Are there any workarounds?
The output of composer create-project acquia/df-project DemoFramework -s dev is the following one.
Creating ...
4
votes
2
answers
1k
views
Composer installing dev modules getting Authentication required (git.drupalcode.org) [closed]
When trying to composer install, and it reaches one of the modules using a Dev version, I get:
- Installing drupal/paragraphs (dev-1.x 42842d5): Authentication required (git.drupalcode.org): Username:
...
1
vote
1
answer
149
views
How can I switch back and forth between globally installed Drush versions?
I installed Drush 8 using cgr (which is a safer replacement for composer global require):
cgr drush/drush:8.x-dev --prefer-source
But now I also want to install Drush 9 for certain sites. Is there a ...
1
vote
0
answers
524
views
PDOException: SQLSTATE[HY000] [2000] on local Docker Drupal Composer site
I've read all the other similar questions and none of the answers have solved the issue. I'm on a Drupal 8 site.
'host' => 'localhost',
'port' => '3306',
'namespace' => 'Drupal\\Core\\...
0
votes
0
answers
108
views
upgrade from 8.9.2 to 9.1.0
I have a drupal 8.9.2 installation with many modules.
I ran upgrade_status and applied patches or upgraded modules to dev version like suggested.
fhebert@fhebert-communication:/var/www/domain.com$ ...
1
vote
0
answers
1k
views
Issues updating core to 9.1.2 with Composer
On my local site, I had updates for 2 modules and Drupal core. To update, I typed in composer update, which had worked for me previously just fine.
Composer indicated everything updated, although on ...
0
votes
0
answers
488
views
"composer update" gives UnexpectedValueException
Locally, I first tried to update core individually using composer update drupal/core drupal/core-recommended --with-all-dependencies. This gave an error, so I just used composer update, which usually ...
-2
votes
1
answer
117
views
Composer keeps reinstalling the same core version
I manually updated a Drupal 9 installation to 9.1.2. I need to install the Real AES module, which depends on the Defuse PHP-Encryption library.
I attempted to install it using Composer, but it tries ...
1
vote
0
answers
54
views
How can I update core without upgrading third-party modules?
This is generally how I update Drupal core:
composer update drupal/core --with-dependencies
However, today when I do this, it is also upgrading the contrib modules. I want to upgrade the core only.
...
0
votes
1
answer
53
views
How can I get hold of the Composer object?
I'm trying to get the file location of something in an installed package.
https://stackoverflow.com/questions/15714809/get-filesystem-path-of-installed-composer-package says I can get that from the ...
-2
votes
1
answer
849
views
How do I update from 9.0.10 to 9.1.0?
I have tried to update drupal 9.0.10 to 9.1 with composer but I cannot:
composer outdated 'drupal/*'
drupal/core 9.0.10 **9.1.0** Drupal is an open source content manage...
drupal/core-...
0
votes
0
answers
109
views
How can I downgrade core? [duplicate]
I have Drupal version 9.1 but the Get JWT on Login module is not available for Drupal 9.x, so I need to downgrade to the latest version of Drupal 8.x. Is it possible to do that through Composer?
0
votes
1
answer
376
views
Drupal module upgrade via Composer not being recognized
A Drupal 8 site started pestering me to upgrade Twig Tweak from 8.x-2.8 to 8.x-2.9. I went to the directory and ran composer require 'drupal/twig_tweak:^2.9' which seemed to work. I also did drush cr. ...
3
votes
2
answers
626
views
How can I use Composer with no Internet access?
I need to build and deploy a Drupal 8 site within an on-premise server with no internet access (developer machines have internet access, and access to a private repo).
I would like to avoid committing ...
0
votes
1
answer
77
views
Custom Theme Repository update
I have a custom theme that I use in several websites.
My theme is on gitlab.
I can download my theme by composer in different websites.
My problem is when I update repository theme with a fix or new ...
8
votes
2
answers
990
views
How do I include composer.libraries.json in root composer.json without using the wikimedia/composer-merge-plugin plugin?
In the recent update to Composer 2.0 the advice is to get rid of the wikimedia/composer-merge-plugin, which was even removed from the dependencies of Drupal core.
There is documentation on how to ...
-5
votes
1
answer
526
views
Removing a patch from Drupal core
I'm using cweagans/composer-patches to apply a patch to drupal/core. When a second developer has pulled down the codebase and run composer install, the installation of drupal/core is failing.
Firstly, ...
11
votes
2
answers
671
views
Patch drupal.org project (core/module/theme) with issue fork
The new fork based merge request (MR) approach is pretty neat to get the patches created/reviewed/merged. However, if you are using the patch via cweagans/composer-patches, we have a few options.
...
3
votes
1
answer
270
views
How can I update core to 8.9.10?
I'm trying to apply the security update for core by updating it to 8.9.10 with the following command:
composer update drupal/core
But this only brings back the following notice:
Nothing to install ...
0
votes
0
answers
86
views
Acquia Dev Desktop create-project Fails With 404 Error at Repository
I am using a brand new installation of Acquia Dev Desktop on Windows 10. When I try to use composer to create a new project I get the following output using the -vvv option:
composer create-project ...
0
votes
1
answer
1k
views
Composer downgrading module version
I wish to move the bootstrap theme from the repository
located in the folder theme/custom to be a dependency in composer.json
I've checked that the current version drupal/bootstrap is 3.16
I perform ...
0
votes
1
answer
114
views
How to uninstall pdf_reader module without error? "The 'core' or the 'core_version_requirement' key must be present"
In summary:
I cannot uninstall pdf_reader sucessfully without bringing down my site with this error:
Drupal\Core\Extension\InfoParserException: The 'core' or the 'core_version_requirement' key must be ...
4
votes
2
answers
21k
views
How can I downgrade a module with Composer?
I updated the following module to its stable version :
https://www.drupal.org/project/commerce_pricelist/releases/8.x-2.0-rc2
This module completely broke my site. There has been no database update. ...
12
votes
3
answers
15k
views
Trouble after updating to 2.0
I got a notice to update composer to 2.0 today and gave it a try, using "composer self-update --2". Now when I run composer update, I'm seeing this message.
The "grasmash/composerize-...
0
votes
1
answer
1k
views
Problem upgrading via Composer
I am currently trying to upgrade my site from drupal 8.9 to drupal 9. I ran these commands to give permissions:
$ chmod 777 web/sites/default
$ find web/sites/default -name "*settings.php" -...
2
votes
1
answer
738
views
How to exclude contributed modules from being upgraded when we run composer install or composer update?
I want to exclude contributed module Ubercart from being upgraded when we run composer install or composer update ? What change should I add in the composer.json so that it ignores ubercart ...