Composer 2.8.1 causing create-project failure in Tugboat previews

Created on 8 October 2024, about 2 months ago

Problem/Motivation

Tugboat builds of this package are currently failing with the following error:

In Factory.php line 308:
                                                                               
  Composer could not find a composer.json file in                              
  To initialize a project, please create a composer.json file. See https://ge  
  tcomposer.org/basic-usage   

In Drupal Slack, it was noted that CI Pipelines was encountering the same issue, and was able to resolve it by downgrading composer to 2.8.0.

Steps to reproduce

Create a Tugboat project using the git provider with https://git.drupalcode.org/project/drupal_cms.git. Then build a preview of the 0.x branch.

Proposed resolution

1. We could add a line to our config.yml to install Composer 2.8.0:

composer self-update 2.8.0

2. OR, if we think this is a bug in Composer, we could wait for Composer to fix this issue upstream.

🐛 Bug report
Status

Active

Component

Infrastructure

Created by

🇺🇸United States q0rban Atlanta, GA

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Merge Requests

Comments & Activities

  • Issue created by @q0rban
  • 🇺🇸United States q0rban Atlanta, GA
  • Pipeline finished with Success
    about 2 months ago
    #304527
  • Pipeline finished with Success
    about 2 months ago
    Total: 580s
    #304528
  • Pipeline finished with Success
    about 2 months ago
    Total: 726s
    #304581
  • Pipeline finished with Success
    about 2 months ago
    Total: 645s
    #304582
  • 🇺🇸United States mtift Minnesota, USA

    Looks good to me!

  • 🇮🇳India arunkumark Coimbatore

    I did the manual review in my local. Below are the steps I followed,

    1. Took the Clone from git@git.drupal.org:project/drupal_cms.git
    2. Checkout to the git checkout -b '3479507--tugboat-composer-2.8.0' --track drupal_cms-3479507/'3479507--tugboat-composer-2.8.0'
    3. Executed ddev composer install
    4. Verified the version, ddev composer --version

    Composer version 2.8.1 2024-10-04 11:31:01
    PHP version 8.3.10 (/usr/bin/php8.3)
    Run the "diagnose" command to get more detailed diagnostics output.
    

    5. Executed ddev composer update
    6. Verified the version, ddev composer --version

    Composer version 2.8.1 2024-10-04 11:31:01
    PHP version 8.3.10 (/usr/bin/php8.3)
    Run the "diagnose" command to get more detailed diagnostics output.
    

    Still, the version shows 2.8.1. I verified the website is working but the expected composer version is not applied my local.

    Please help me the way tested the correct?

  • 🇺🇸United States phenaproxima Massachusetts

    Thanks @arunkumark. This is actually only in our Tugboat configuration so it won't be something you can reproduce locally. I think the change looks fine and I'm comfortable merging it.

  • 🇺🇸United States phenaproxima Massachusetts
  • Pipeline finished with Skipped
    about 1 month ago
    #310277
  • 🇺🇸United States phenaproxima Massachusetts

    Merged into 0.x. Thanks, everyone!

  • Automatically closed - issue fixed for 2 weeks with no activity.

Production build 0.71.5 2024