Skip to content

Composer 2.9 Broken GitHub Actions CI #12600

@samharvey44

Description

@samharvey44

Following the release of Composer 2.9, the following error has began appearing in our GitHub Actions CI:

Image

Here is the yml file of the failing script:

name: Run PHPUnit Tests

on:
    pull_request:
        branches: [ master ]

concurrency:
    group: phpunit-tests-${{ github.ref }}
    cancel-in-progress: true

jobs:
    phpunit-tests:
        runs-on: ubuntu-latest
        timeout-minutes: 10

        steps:
            -   name: Checkout code
                uses: actions/checkout@v4

            -   name: Setup PHP
                uses: shivammathur/setup-php@v2
                with:
                    php-version: '7.4'
                    coverage: none
                    tools: composer:v2

            -   name: Install dependencies
                run: composer install --no-interaction --no-progress --prefer-dist

            -   name: Run PHPUnit
                run: composer test

Locking the Composer version to 2.8.4 (i.e. tools: composer:2.8.4) fixes the issue.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions