Composer - Fehler: Your requirements could not be resolved to an installable set of packages.
am 07.02.2022 - 18:56 Uhr in
Hallo,
ich habe mein Composer auf version 2.1.9 geupdated. Leider funktioniert jetzt ein update bzw. das Installieren von Modulen nicht mehr. Folgendes hatte ich versucht:
composer update --no-plugins
> DrupalProject\composer\ScriptHandler::checkComposerVersion
Loading composer repositories with package information
Updating dependencies
Your requirements could not be resolved to an installable set of packages.
Problem 1
- drupal-composer/drupal-scaffold[2.5.0, ..., 2.6.1] require composer-plugin-api ^1.0.0 -> found composer-plugin-api[2.1.0] but it does not match the constraint.
- Root composer.json requires drupal-composer/drupal-scaffold ^2.5 -> satisfiable by drupal-composer/drupal-scaffold[2.5.0, ..., 2.6.1].
Aber wie kann ich das Problem jetzt lösen? Wenn ich mir die aktuelle composer.json von der Drupal Version 8.8 ansehe:
https://github.com/drupal/recommended-project/blob/8.8.x/composer.json
steht im "core-composer-scaffold" part:
"require": {
"composer/installers": "^1.2",
"drupal/core-composer-scaffold": "^8.8",
"drupal/core-project-message": "^8.8",
"drupal/core-recommended": "^8.8"
},
Soll ich den jetzt einfach in meine aktuelle composer.json nachtragen? Die sieht nämlich wie folgt aus:
{
"name": "drupal-composer/drupal-project",
"description": "Project template for Drupal 8 projects with composer",
"type": "project",
"license": "GPL-2.0-or-later",
"authors": [
{
"name": "",
"role": ""
}
],
"repositories": [
{
"type": "composer",
"url": "https://packages.drupal.org/8"
}
],
"require": {
"php": ">=7.0.8",
"behat/mink-selenium2-driver": "dev-master as 1.3.x-dev",
"composer/installers": "^1.2",
"cweagans/composer-patches": "^1.6.5",
"drupal-composer/drupal-scaffold": "^2.5",
"drupal/adminimal_admin_toolbar": "^1.10",
"drupal/adminimal_theme": "^1.5",
"drupal/aet": "2.x-dev@dev",
"drupal/backup_migrate": "^4.0",
"drupal/business_rules": "2.x-dev@dev",
"drupal/ckeditor_accordion": "1.x-dev@dev",
"drupal/ckeditor_font": "1.x-dev@dev",
"drupal/commerce": "^2.16",
"drupal/commerce_feeds": "^1.0@alpha",
"drupal/console": "^1.0.2",
"drupal/context": "4.x-dev",
"drupal/core": "^8.7.0",
"drupal/datatables": "1.x-dev",
"drupal/devel": "^2.1",
"drupal/diff": "^1.0",
"drupal/ds": "^3.4",
"drupal/entity_print": "2.x-dev",
"drupal/entity_usage": "^2.0",
"drupal/fancy_login": "^2.2",
"drupal/feeds": "3.x-dev",
"drupal/feeds_para_mapper": "1.x-dev",
"drupal/feeds_tamper": "^2.0@beta",
"drupal/field_group": "^3.0",
"drupal/flag": "^4.0@alpha",
"drupal/foundation_layouts": "^6.0",
"drupal/go_back": "^1.5",
"drupal/go_back_history": "^1.0",
"drupal/inline_entity_form": "^1.0",
"drupal/isbn": "^1.1",
"drupal/libraries": "^3.0@alpha",
"drupal/menu_token": "1.x-dev@dev",
"drupal/module_filter": "^3.1",
"drupal/node_token": "^1.1",
"drupal/pagebreak": "^1.0",
"drupal/paragraphs": "^1.12",
"drupal/paragraphs_inline_entity_form": "^1.0@beta",
"drupal/patchinfo": "^1.1",
"drupal/pathauto": "^1.8",
"drupal/php": "1.x-dev@dev",
"drupal/printfriendly": "^3.4",
"drupal/reference_table_formatter": "1.x-dev",
"drupal/revision_log": "1.x-dev@dev",
"drupal/revision_log_default": "^1.2",
"drupal/rules": "3.x-dev@dev",
"drupal/rules_ban": "^3.0@alpha",
"drupal/rules_conditional": "1.x-dev@dev",
"drupal/show_title": "^1.5",
"drupal/super_login": "^1.3",
"drupal/svg_image": "^1.15",
"drupal/tablefield": "^2.1",
"drupal/token": "^1.9",
"drupal/token_custom": "^1.0@alpha",
"drupal/token_filter": "1.x-dev@dev",
"drupal/total_control": "^2.0@beta",
"drupal/tr_rulez": "1.x-dev@dev",
"drupal/vardumper": "^1.5",
"drupal/vbo_export": "^3.1",
"drupal/view_mode_page": "3.x-dev",
"drupal/view_modes_display": "^2.2",
"drupal/views_bulk_operations": "^3.3",
"drupal/views_cumulative_field": "^1.5",
"drupal/views_data_export": "1.x-dev",
"drupal/views_simple_math_field": "2.x-dev@dev",
"drupal/zurb_foundation": "^6.0",
"drush/drush": "^9.0.0",
"firephp/firephp-core": "^0.5.3",
"mikehaertl/phpwkhtmltopdf": "~2.1",
"phpoffice/phpexcel": "1.8.0",
"phpoffice/phpspreadsheet": "^1.6",
"phpoffice/phpword": "^0.17.0",
"tecnickcom/tcpdf": "~6",
"vlucas/phpdotenv": "^2.4",
"webflo/drupal-finder": "^1.0.0",
"webmozart/path-util": "^2.3",
"zaporylie/composer-drupal-optimizations": "^1.0"
},
"require-dev": {
"webflo/drupal-core-require-dev": "^8.7.0"
},
"conflict": {
"drupal/drupal": "*"
},
"minimum-stability": "dev",
"prefer-stable": true,
"config": {
"sort-packages": true
},
"autoload": {
"classmap": [
"scripts/composer/ScriptHandler.php"
],
"files": ["load.environment.php"]
},
"scripts": {
"pre-install-cmd": [
"DrupalProject\\composer\\ScriptHandler::checkComposerVersion"
],
"pre-update-cmd": [
"DrupalProject\\composer\\ScriptHandler::checkComposerVersion"
],
"post-install-cmd": [
"DrupalProject\\composer\\ScriptHandler::createRequiredFiles"
],
"post-update-cmd": [
"DrupalProject\\composer\\ScriptHandler::createRequiredFiles"
]
},
"extra": {
"composer-exit-on-patch-failure": true,
"patchLevel": {
"drupal/core": "-p2"
},
"installer-paths": {
"web/core": ["type:drupal-core"],
"web/libraries/{$name}": ["type:drupal-library"],
"web/modules/contrib/{$name}": ["type:drupal-module"],
"web/profiles/contrib/{$name}": ["type:drupal-profile"],
"web/themes/contrib/{$name}": ["type:drupal-theme"],
"drush/Commands/contrib/{$name}": ["type:drupal-drush"]
},
"drupal-scaffold": {
"initial": {
".editorconfig": "../.editorconfig",
".gitattributes": "../.gitattributes"
}
}
}
}
Oder doch wieder einen Rollback auf composer der einer Version? Würde ich aber gerne vermeiden, denn wollte auch eigentlich mal ein Update auf Drupal 9 machen.
Danke und Grüße
Bavra
- Anmelden oder Registrieren um Kommentare zu schreiben
Zitat: "require": {
am 09.02.2022 - 10:53 Uhr
"require": {
"composer/installers": "^1.2",
"drupal/core-composer-scaffold": "^8.8",
"drupal/core-project-message": "^8.8",
"drupal/core-recommended": "^8.8"
},
Ich würde (nach einem Backup) einfach den Versuch starten , die Version des Installers auf "^2.0" zu setzen und zu testen, was passiert
.
Werner
drupal-training.de
Moderator und Drupal Trainer
* - - - - - - - - - - - - - - - - - - - - - - - - - - - *