Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [composer]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
1 vote
2 answers
89 views

Unable to install plugins in Craft 4 production

I am upgrading from Craft 2 to Craft 4 and this is the first time I'm deploying a Craft 4 website. It was entirely unclear how to do this, as just uploading the files to an FTP server does not work ...
Branko's user avatar
  • 13
1 vote
1 answer
233 views

PHPdotEnv upgrade not working

Updating my Craft CMS website to Craft 3.8 on PHP 8.1 yielded the first of its kind: the fatal deprecation error that would not allow the migration to continue. Turns out, PHPdotEnv v 2.8 is too old: ...
Caroline Blaker's user avatar
2 votes
2 answers
1k views

Monolog Logger error

<Irrelevent preliminary context> Somewhere in the process not understanding modules and whether they get to have Variable classes, and running php craft make module and composer dump-autoload -a ...
kr37's user avatar
  • 1,355
0 votes
0 answers
57 views

composer update for Craft 3 to Craft 4

Trying to migrate a site from Craft 3 to Craft 4. Carefully followed the instructions to update my composer.json file to reflect the Craft 4 versions of Craft and all plugins. When I run composer ...
Roi Agneta's user avatar
  • 1,463
0 votes
0 answers
34 views

Interface "React\Promise\ExtendedPromiseInterface" not found

So I upgraded the page from Craft 2.9 to latest 3.x.x version. Now I am trying to install a plugin and I get this error - any help? Cheers
Zoruak's user avatar
  • 11
1 vote
1 answer
33 views

Composer error when adding imager-x plugin

Error: "https://composer.craftcms.com/p2/aws/aws-sdk-php.json" does not contain valid JSON Parse error on line 1: ...pball\/6690347bc833"https:\/\/api.github ----------------------^ ...
JYdigital's user avatar
1 vote
1 answer
245 views

PHP version problem when upgrading to Craft CMS 4

I am upgrading a site from Craft CMS 3 to 4. I develop the site on ddev with docker desktop on Windows. When running composer update on PHP 7.4 and docker 2 on ddev the following happens: $ ddev ...
nitech's user avatar
  • 679
1 vote
1 answer
49 views

How to install Craft Commerce Shopping Feed Pro plugin

I'm attempting to install the Craft Commerce Shopping Feed Pro plugin using the following: composer require kerosin/craft-google-shopping-feed-pro But I'm getting the following error: Could not find a ...
MrCarrot's user avatar
  • 121
1 vote
1 answer
32 views

Containerising composer dependencies in DDEV (Generalised question)

So the other day I was queried about Composer dependencies and potential risks for different locally installed packages to clash or cause version issues. Since then I have done a little bit of digging ...
Wally's user avatar
  • 343
2 votes
1 answer
79 views

Problem with composer path when installing plugins

so I have Craft installed in a directory called 'cms' which is above webroot, I changed the main index file to use; require dirname(__DIR__) . '/cms/bootstrap.php'; The main reason for this is because ...
Greg Findon's user avatar
1 vote
0 answers
105 views

Craft4 Upgrade did not create filesystem entries

I'm making a post about this as a form of documentation of an issue I ran into while upgrading one of my sites to Craft4. I followed the upgrade instructions and got the site upgraded to the latest ...
Rick Kukiela's user avatar
1 vote
1 answer
1k views

Composer was unable to install the updates. Error: Unknown package has no name defined

Hi I cannot install Craft CMS updates. I have version 3.1.18 and I'm trying to update to 3.7.50 I have updated Composer successfully. I did however have a platform PHP 7 issue listed in composer.json ...
cannon303's user avatar
  • 309
3 votes
1 answer
1k views

Your project config YAML files are expecting different versions to be installed

I'm working on a site on shared hosting and I can't run composer install from CLI to install the vendor folder because I get The Process class relies on proc_open, which is not available on your PHP ...
Tyssen's user avatar
  • 653
1 vote
1 answer
187 views

Error when running composer commands

I'm getting an error with almost every Craft project I set up when I try and run any composer command: Parse error: parse error, expecting `';'' or `'{'' in /path-to-my-project/craft/vendor/craftcms/...
Mark's user avatar
  • 287
1 vote
1 answer
92 views

Difficulties to setup a Filter class

This question is following this one: Where to implement Craft Webhook FilterInterface. I'm trying to implement a Craft Webhook FilterInterface but failed to load it. Below is the content of my setup, ...
Romain P.'s user avatar
  • 1,852
0 votes
0 answers
204 views

Composer needs GitHub token to update craft cms

I was on craft v3.7.24, but I needed bugfixes in 3.7.25.1. Both Craft update console command and composer told me they couldn't authenticate against GitHub and/or needed an API token. composer update ...
S. Parton's user avatar
1 vote
1 answer
238 views

Upgrading to 3.7.26 causes tempnam() error from twig's FilesystemCache.php

I am upgrading a Craft project that I have been neglecting for a little bit too long. I am upgrading to 3.7.26 from 3.4.25; on top of this, I am upgrading from PHP 7.1 to PHP 7.4. I'm also updating a ...
Rob Erskine's user avatar
1 vote
1 answer
207 views

Composer error while upgrading from Craft CMS 3.5.8 to 3.7.21

I am trying to upgrade to the Craft CMS from 3.5.8 to 3.7.21. I am getting the below error. Any help really helpful. Output: <warning>Package "craftcms/vue-asset" listed for update is ...
JohnC's user avatar
  • 61
2 votes
1 answer
36 views

Child (inner) Path of backend in Virtual Host is possible?

I have ISP Config host virtual website which is a system tool to host many websites. Document root path '/' is not writable. I have an /private, which is writable. I used alias @root as /private, and ...
cooltronic.pl's user avatar
1 vote
1 answer
58 views

Composer Unexpected end of file on new plugin

I'm making a new Plugin for CraftCMS, it works fine locally but when I call the services class on our staging server it throws a Syntax Error, Unexpected end of file. I've installed them both through ...
samroberts707's user avatar
1 vote
1 answer
804 views

Error when trying to update Craft or install any plugin

When I try to update Craft, or install any plugin from the plugin store, I get the following error): Composer was unable to install the updates. Error: The url supplied for the path (plugins/redactor)...
Jake1293's user avatar
  • 159
1 vote
1 answer
97 views

Class '...SiteModuleService' not found when used inside scout.php

I have a custom SiteModule that is used inside scout.php to deliver indexing data to Algolia. I have followed CraftQuest's tutorial on creating a custom SiteModule for handling the indicies. The setup ...
nitech's user avatar
  • 679
2 votes
1 answer
934 views

Where exactly to update the composer.json to install an older version of Craft 3?

I'm trying to install a non-current version of Craft 3, and several pointers on using composer to do this say to "update the composer.json" line with the version you want. Can someone please ...
RocksaltAU's user avatar
2 votes
1 answer
776 views

Error with Craft CMS set up and composer: failed: SQLSTATE[HY000] [1045] Access denied for user 'root'@'localhost' (using password: YES)

Hi I am trying to set up craft CMS with composer. I am using MAMP on a mac and I just cannot get it to connect. I get this error even though I know the password is correct. failed: SQLSTATE[HY000] [...
cannon303's user avatar
  • 309
1 vote
1 answer
229 views

Configure path craft uses for composer and php

Is it possible to configure the PATH to composer that craft is using? In a shared hosting (our server, lots of sites) php isn't available by default. It's provided via redhat software collections. ...
Derak's user avatar
  • 131
2 votes
1 answer
5k views

"Error: Unknown package has no name defined" when updating Craft 3

I'm getting "Error: Unknown package has no name defined" when updating a site from 3.0.41.1 to 3.5.15.1 I had read a reinstall of composer had fixed this for someone else, but hasn't for me. ...
Jaytrix's user avatar
  • 337
1 vote
1 answer
72 views

Can't install Transcoder plugin

Not sure whether I should be posting this here or as a Github issue, but when trying to install NY Studio's Transcoder plugin, I get: Composer output: Package "craftcms/vue-asset" listed ...
Tyssen's user avatar
  • 653
1 vote
1 answer
201 views

There are no sites in the config file on nitro add

When i try nitro add command to they return "There are no sites in the config file" what should i do? Unable to locate a webroot, setting to web. Enter the webroot [web] web Added tutorial....
Pedro's user avatar
  • 11
2 votes
1 answer
92 views

dev- branch plugin forks being prompted for update

I'm currently using a fork of a plugin for my site, and using a "dev-[branch-name]" version specification in the composer "require" block, with a "vcs" repository ...
Jegra's user avatar
  • 81
14 votes
7 answers
43k views

"Unknown package has no name defined" composer error on upgrade

Upgrading from Craft 3.4.20 running Composer 1.10.17 on PHP 7.2. Running ./craft update all returns the following error: error: Unknown package has no name defined. [followed by JSON object related to ...
Jason's user avatar
  • 348
1 vote
1 answer
327 views

Testing database credentials Craft 3 Setup

When i try setup db in craft 3 at windows with composer using php craft setup/db command it give me Which database driver are you using? [mysql,pgsql,?]: pgsql Database server name or IP address: [127....
Pedro's user avatar
  • 11
1 vote
1 answer
101 views

Why does Bootup.php run with PHP 5.4.16 from with Craft script but PHP 7.4.10 from the terminal command line?

This is a problem encountered apparently by a lot of users when installing from the Craft setup/install files from the Craft web site. PHP Warning: Unsupported declare 'strict_types' in /var/craft/...
it's a hire car baby's user avatar
1 vote
1 answer
32 views

Craftnet API package query

Does querying composer packages via the Craftnet API need authentication? Ref https://docs.api.craftcms.com/packages.html Querying the Craft CMS package itself is fine, eg https://api.craftcms.com/v1/...
Cole Henley's user avatar
  • 1,741
1 vote
1 answer
980 views

Craft CMS issue with Composer V2

We have a website built in Craft 3.4.14 and we are moving it to a hosting company with CentOS 7, using Plesk Obsidian 18.0.5. The hosting company has told us that they have upgraded Composer from ...
matt_orch's user avatar
0 votes
0 answers
82 views

How to move a plugin from dev to prod?

I have a plugin that I developed in a symlinked folder locally. I now want to deploy it to production. But when I do composer require namespace/pluginhandle it gets symlinked. What I want is to ...
Crafty Cat's user avatar
2 votes
1 answer
8k views

composer update missing zip extension (ext-zip) on MacOS

When doing a composer update in a Craft project on MacOS Catalina, I suddenly get the following error: ***** requires ext-zip * -> the requested PHP extension zip is missing from your system. Any ...
Matthias Redl-Mann's user avatar
1 vote
1 answer
144 views

Weird issue with craft/setup command

I have been trying to install Craft CMS on Windows. I tried composer: composer create-project craftcms/craft d:\temp\craft After that when I try to craft setup there is a loop on the console which ...
Rohit's user avatar
  • 121
1 vote
1 answer
397 views

"Could not find composer.json file" error in CraftCMS 3

I recently updated my CraftCMS 3 with the help of Composer. When I try to install a plugin with the plugin store, I get an error saying that Craft couldn't find my composer.json file. He proposes me ...
Mikko109's user avatar
1 vote
1 answer
928 views

Allowed memory size of 1610612736 bytes exhausted when updating via CLI on OS X

This one has been bugging me for months. My development environment is running on MAMP on OS X. It's worked absolutely find for ages but for no reason that I can identify all my Craft sites now ...
neekster's user avatar
  • 403
2 votes
1 answer
1k views

PS-4 Autloading custom module

I have created a module in modules/Core.php which works great and I can reference it using modules\Core::class. But I want to re-organise my modules. I'm not super familiar with PSR-4 loading but I ...
Callum's user avatar
  • 193
2 votes
1 answer
569 views

How to manage breakpoint releases when updating Craft via composer

When logged in to Craft, the "Utilities" tab will show you all the latest releases you can update to. In some cases, it will report that you have reached a breakpoint release: You’ve reached a ...
Ben Parizek's user avatar
  • 13.5k
1 vote
1 answer
90 views

Update issues on local laravel valet

When I update any plugins ( and I mean any not specific) the vendor package vlucas (Php DotEnv) is removed and the site subsequently breaks complaining it cannot find the DOT env file. Manual update ...
joomkit's user avatar
  • 2,024
1 vote
1 answer
865 views

composer.json file not updating when plugins are updated

My composer.json file doesn't update to the latest plugin versions when I update my plugins via the Craft CP or command line.
user3092's user avatar
  • 117
1 vote
1 answer
42 views

Faceted navigation plugin problem installing

I get the errors below in the Command Prompt when trying to install. helloswish/craft-faceted-navigation Does anyone know why this is not working? [InvalidArgumentException] Could not find a ...
Malcolm Maclean's user avatar
2 votes
1 answer
425 views

What is the correct way to update a production site with composer?

I disable admin updates on production sites, and update Craft and its plugins by updating in the development environment, and then deploying to production using Git. My basic process starts like this: ...
Mark Northrop's user avatar
3 votes
1 answer
331 views

Composer require looking to craft/plugins/[plugin] directory but throws runtime error?

I've got Craft 3.1.32 up and running on dev machines and we're ready to get it into our test/stage enviromnments, which are built through a GitLab CI/CD. While doing this, we noticed some plugins ...
Greg Bowne's user avatar
5 votes
5 answers
23k views

Carbon 1 is deprecated - migrate to Carbon 2

Is anyone getting this when running a composer update command? Local install: Craft CMS 3.1.31 update --no-interaction --ansi  Loading composer repositories with package information  Updating ...
Nutmeg's user avatar
  • 598
3 votes
3 answers
1k views

cannot update Craft CMS - composer errors

I'm upgrading a site to 3.0.41.1 (not ready to go to 3.1) and when I do I get the following error. How do I resolve this? composer update craftcms/cms Loading composer repositories with package ...
CreateSean's user avatar
  • 1,973
1 vote
1 answer
2k views

Getting my head round installing plugins from the command line

My command line skills are limited but I’m trying to be better. I’ve been using composer successfully for a while to initiate Craft installs, but then subsequently using the Craft web GUI to install ...
Jonathan Schofield's user avatar
2 votes
1 answer
59 views

Possible to reflect changes to a plugin's composer.json without uninstall/reinstall?

When working on a plugin recently, I decided to add a CP section: composer.json { ... "extra": ... "hasCpSection": true ... } The only way that I was able to have this ...
Chris's user avatar
  • 137