Skip to content

In Command.php line 171: Call to a member function make() on null #56098

@laze

Description

@laze

Laravel Version

12.17.0

PHP Version

8.3

Database Driver & Version

No response

Description

When I run composer update command Laravel always dies when calling @php artisan package:discover --ansi both on local docker environment and gitlab runner's machine.
First I tried with 12.19.x, the most recent Laravel and then I began to decrease Laravel's version, without any result.
As I debug, the problem is, that in the Command file's constructor does not know $this->laravel, even if the app() returns with that.
If I put $this->laravel = app(); into the Command's constructor manually then run composer update again then it works well, but I can't do that on deploy or live environment.

Steps To Reproduce

Run composer update

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions