Questions tagged [composer]
Use it for questions about the PHP application library dependency manager (Composer).
601
questions
0
votes
1
answer
23
views
How to remove a region from a content type? [closed]
Drupal 10.1.3
How to remove a region from a content type?
In Drupal 7 or Drupal 8 I did that with a condition-reaction in the module Context but I am having trouble installing the module Context in ...
-3
votes
1
answer
64
views
How I can use Drush for portal deployment and redeployment?
I have downloaded Composer on a Windows 11 computer. I have installed Drush with composer require drush/drush, or maybe composer global require drush/drush.
As I haven't mentioned any specific version,...
-4
votes
0
answers
46
views
My shared hosting doesn't have up to date libmysqlclient for Drupal 10, what latest core version can work? [duplicate]
My shared hosting provider doesn't have up-to-date libmysqlclient so I can't finish the Drupal 10 installation.
The libmysqlclient driver version 3.1.21 is less than the minimum required version. ...
0
votes
0
answers
42
views
Getting existing composer managed site to legacy-project composer managed
[Update] I seem to be making some actual progress by just replacing the the composer.json with https://github.com/drupal/legacy-project/blob/8.9.x/composer.json and then doing a composer require [all ...
-5
votes
0
answers
51
views
Permission Denied and Symlink failed, fallback to use mirroring
In the Drupal multisite application, I upgraded to Drupal 10. But when I try to update the database it throws me a permission denied error, so I deleted the contrib, vendor and composer lock file and ...
0
votes
0
answers
44
views
Composer.lock does not match project versions
I have a drupal site developed using the core-recommended project, and I maintain the site using the recommended practices on drupal.org.
Recently after adding a new developer to the project, Composer ...
1
vote
0
answers
75
views
Fatal error: concerning DrushStyle::warning not being compatible with SymfonyStyle::warning
I just upgraded our site from Drupal 9.5.9 to Drupal 10.1 (following instructions from here - https://www.drupal.org/docs/upgrading-drupal/upgrading-from-drupal-8-or-later/upgrading-a-composer-based-...
-1
votes
1
answer
51
views
Can not get the module by composer [closed]
My Drupal Version is 9.5.10
PHP Version 8.1.18
I am trying to get the module:
composer require 'drupal/rocket_chat:^3.0'
But unsuccessful:
Problem 1
Root composer.json requires drupal/rocket_chat, it ...
0
votes
2
answers
130
views
Why don't these Composer dependencies allow upgrading to Drupal 10?
I'm currently on Drupal Version 9.5.10, and I cannot update to Drupal 10 due to some depdendancy conflicts.
I updated my database, cleared cache, ran a cron. It doesn't fix.
How can I upgrade to ...
2
votes
3
answers
370
views
Unable to upgrade from Drupal 9.5.10 to 10.1.1
I'm stuck on my efforts to upgrade my sites (I have 5 in total that I manage) from Drupal 9.5.10 to 10.1.1. I'm using PHP 8.1.8.
I'm following the instruction from https://www.drupal.org/docs/...
1
vote
2
answers
79
views
Is Drupal Commerce compatible with Drupal 10?
Don't see this answered anywhere.
I have Drupal 10 installed, as a dev site cohabiting with a live Drupal 7 on the same server. I don't use composer for the D7 install, but can't get it to work on ...
-4
votes
2
answers
349
views
Why doesn’t "composer update" upgrade this site?
I'm running Drupal 9.59. I tried following the instructions on drupal.org for upgrading to Drupal 10. The steps with composer --no-update went fine. The actual update step yields:
Loading composer ...
0
votes
0
answers
193
views
Composer install times out with a bind-mounted volume running Composer through Docker
I've been working on trying to set up a Drupal 10 local development instance on my Windows machine and keep running into an issue of the Drupal installation failing when I have a volume mounted.
...
-2
votes
1
answer
36
views
Errors Thrown by Composer and Drupal Core [closed]
I'm working as a part of a development team where my colleagues (team members) work in separate Git branches created out of and then merging their branches into a common development branch, develop.
...
0
votes
1
answer
142
views
How can I patch a Composer dependency to make the dependency compatible with other dependency versions? [duplicate]
I'm trying to update my site from D9 to D10, I've had quite a lot of modules to go through, and for the most part a lot of them have releases which are stable for D10, but roughly 4-5 of them only ...
1
vote
0
answers
87
views
Unable to reinstall Admin Toolbar in modules directory
All my modules are in the web/modules/ directory except for Admin Toolbar which is in web/modules/contrib/. (Why? Long story, legacy site.) Admin Toolbar refuses to update now because of the ...
-1
votes
2
answers
382
views
Why is cweagans/composer-patches not installing this patch? [closed]
I'm trying to apply different patches but after the command composer install nothing happens. Output:
Installing dependencies from the lock file (including require-dev)
Verifying lock file contents ...
0
votes
1
answer
68
views
Troubleshooting issue forks to make core version compatibility fixes
During the Drupal 8->9 upgrade, we noticed an issue where module maintainers had abandoned a project or were not responding to merge requests in a timely manner. As you know, composer doesn't care ...
-2
votes
1
answer
284
views
Issues updating from 9.4.3 with composer
I have a project that wasn't updated since a few months and I am stuck on 9.4.3 with composer refusing to update.
Here is my composer.json
{
"name": "drupal-composer/drupal-project&...
0
votes
1
answer
54
views
Should I "composerize" my installation?
So; having been involved with a D7 / CiviCRM build a number of years ago, I started building a D10/CiviCRM build as a project to suggest to my local organisation.
I think I might have caused myself an ...
0
votes
2
answers
647
views
Run composer installed drupal from root (/) and not /web directory
How do I run a composer-installed Drupal site from / instead of /web?
The default install with composer create-project drupal/recommended-project ./ will install Drupal in the /web directory. So when ...
0
votes
1
answer
409
views
Cannot apply patch; file not found [closed]
There is a specialized fix to a contrib theme that I am trying to apply. Because this theme is in the .gitignore file, it's incumbent upon me to generate a patch that composer can include. Please note ...
0
votes
0
answers
38
views
PHP Error: Drush\Application::setLogger(Psr\Log\LoggerInterface $logger) must be compatible in two given files | How to fix this error? [duplicate]
I was trying to setup a local environment of a website created on Acquia cloud platform. Everything was done properly including the database import. But now, when I execute drush commands, it gives me ...
0
votes
1
answer
101
views
Convert Drupal 8.6 site to Composer (after D8 end of life)? [closed]
Client has a sqldump and a tarball of a broken Drupal site.
Instead of using Composer to set up the recommended project, it looks like the previous developer performed a git checkout of http://git....
0
votes
1
answer
63
views
Migrate webform directory with Composer from manual installation
I'm started drupal project (core 9.5.2) installing modules manually (it is not good, i know). After the website is deployed in production, I made changes for configuring composer and all worked well.
...
-3
votes
1
answer
555
views
Best practice to upgrade drupal 9.4 to 9.5? Composer or Drush method? [closed]
I can run this command to upgrade drupal 9.4 to 9.5, but I can also do it in drush. Which method is better and why?
composer require drupal/core-recommended:9.5.0 drupal/core-composer-scaffold:9.5.0 ...
-3
votes
1
answer
322
views
"Your requirements could not be resolved to an installable set of packages." [closed]
cPanel PHP Version: 7.3
Drupal 8.8
I am trying to install upgrade_status module via composer for the first time in a shared hosting server but I am unable to do that. Below shows the error that I get.
...
5
votes
2
answers
2k
views
Why doesn't cweagans/composer-patches install my custom patch for drupal/slick?
Basically, I have installed slick module and customised code and created a patch file using "git diff" command. Slick module file path is modules/contrib/slick/ directory. Below is the code ...
0
votes
1
answer
633
views
Problem with PHP version on Ubuntu on Windows when installing Drush
I'm trying to install Drupal 10 with DDEV with these instructions: https://ddev.readthedocs.io/en/latest/users/quickstart/#drupal.
I'm on Ubuntu on Windows (WSL2).
Ubuntu version: 20.04.
Windows 10.
...
0
votes
1
answer
582
views
Drush fatal error with Declaration of Drupal\Core\Logger\LoggerChannel::log [closed]
When I run any drush command or even just drush I get the fatal error:
Fatal error: Declaration of Drupal\Core\Logger\LoggerChannel::log($level, $message, array $context = []) must be compatible with ...
0
votes
0
answers
216
views
How can I provide composer with a twig version that it's okay with, so I can roll back Drupal to a version that will work with PHP 7.4?
I inherited a broken Drupal 9 site. Drush could not be made to work, so I deleted the vendor directory, renamed composer.lock and reinstalled. This has worked for me before on broken sites. Now I ...
5
votes
1
answer
3k
views
Composer not applying patch: exceeded the timeout of 300 seconds [closed]
Since my update to the new OSX (Ventura 13) I'm having problems using composer. The biggest problem I have is that my patches aren't patched and end up with and exceeded the timeout of 300 seconds ...
-1
votes
1
answer
501
views
Why is core installed into the vendor directory?
When I am trying to upgrade module or theme via Composer, I get this exception.
Fatal error: Cannot redeclare config_get_config_directory() (previously declared in D:\xampp\htdocs\itdlocal_test\web\...
-2
votes
1
answer
740
views
phpstan error installing Upgrade Status module [closed]
I'm on a freshly updates site running PHP 8.1.12. I followed the instructions on the module page. Worked fine till the final step when it failed.
Problem 1
- mglaman/phpstan-drupal[1.0.0, ..., 1....
0
votes
0
answers
75
views
Issues updating opigno_lms from 2.16.0 -> 2.29.0 -> 3.x using composer
Having an issue with updating an old Opigno server from 2.16 to 3.0 via 2.29. For those unfamiliar, it's a distribution of Drupal that has some extra features for lessons, courses, etc.
When ...
0
votes
1
answer
655
views
Composer not respecting constraint defined in composer.json
I have a build, with the following constraint on drupal/core, for some reason the constraint is not respected.
Upon running composer install this comes up:
- Downloading drupal/core (9.5.0-rc1)
...
1
vote
1
answer
49
views
Is there an equivalent of "drush dl pathauto --select" using "composer require module" name?
Coming from drush 7. I used to install modules using "drush dl module_name --select" and I get a list of module versions I can select to download. Is there an equivalent for this for drupal ...
0
votes
1
answer
2k
views
How do I resolve these update errors?
Edit: I removed a couple modules that I thought might be causing the issue and uploaded the new error code.
Edit 2: I cut some of the error code stuff to have the room to fit my composer.json file ...
1
vote
1
answer
466
views
How to properly downgrade an existing Drupal installation to a lower PHP version?
I've got a site smoothly running on Drupal 9.4.8 and PHP 8.1. Now I would like to enable APCu in PHP, but my provider unfortunately has installed APCu for PHP 8.0 only. If I simply switch to PHP 8.0, ...
2
votes
1
answer
402
views
Adding library charts.js to composer.json [closed]
I've installed module Moderation Dashboard, now I would like to install charts.js, which is needed by the module, locally by using composer.
The readme of the module says:
Add following code inside ...
0
votes
1
answer
463
views
Composer upgrade to 9.4.x fails, my site is stuck on 9.3.x
My Drupal 9 site is stuck on the 9.3.x track, I cannot upgrade to 9.4.x. If I use the standard upgrade command:
composer update "drupal/core-*" --with-all-dependencies
Then it upgrades to ...
1
vote
1
answer
943
views
How can I have "minimum-stability": "stable" in my composer.json and install alpha version of a contrib module?
Trying to update Drupal core to 9.4.7 with composer update "drupal/core-*" --with-all-dependencies, I got 9.5.0-beta1 version.
Digging a little in Drupal Answers, I found 'Update installs a ...
0
votes
2
answers
205
views
RuntimeException when updating from command line
I went to my website's directory and ran:
composer update
[RuntimeException]
Could not delete /home/example/public_html/example.com/web/sites/default/default.services.yml:
ls -la output:
-rw-rw-r-- ...
-3
votes
1
answer
407
views
How to remove a module with command line?
After uninstalling all relevant modules with drush un I have tried the following input and got the following output, but I don't think I did it correctly.
composer remove vendor/panels
vendor/panels ...
0
votes
1
answer
392
views
Why does ckeditor_config make it impossible to update Composer packages?
I've got a Drupal 9.4 site that I've upgraded my database stack (XAMPP dev stack) to the latest version that is using php 8.1, but now have package incompatibilities showing up when I try to run "...
0
votes
1
answer
249
views
I cannot update packages because https://www.drupal.org/9/packages.json cannot be downloaded
Trying to do a simple composer update of my core Drupal packages to the latest recommended version, and I'm being hit with a 404 and it won't update.
The error Composer spits out when running composer ...
1
vote
0
answers
90
views
Cannot enable file-mapping option in a composer.json to prevent custom edits to be overridden in .htaccess
I have a "drupal/legacy-project" Drupal 9 project (it was packed inside bought custom drupal theme and later updated to latest drupal 9 version) and I need some custom edits in my root ....
1
vote
1
answer
78
views
Why do I get the development snapshot?
I am following the instructions given on Updating Drupal core via Composer for users using the drupal/core-recommended package.
I have the following lines in the composer.json file.
"minimum-...
-3
votes
1
answer
103
views
composer drupal-core update fail because of zetacomponents/mail patch
I try to update a Drupalmachine on 9.4.5 site via composer 2.4.1.
~/bin/composer.phar update drupal/core "drupal/core-*" --with-all-dependencies (see below for composer.json)
first try i can ...
0
votes
0
answers
187
views
I cannot install a module
I have installed a Drupal 8.0.0 local test site in Windows 7 and I am trying to install Devel via Composer, running: composer require drupal/devel:^4.1. I get the following message in the command line:...