Skip to content

Internal errors with array parameters #156

Closed

Description

@Seldaek

This code here makes PHPStan crash with this extension enabled:

    Internal error: Internal error: Unexpected expression type PHPStan\Type\ArrayType in file /var/www/packagist/src/Command/IndexPackagesCommand.php
     Run PHPStan with --debug option and post the stack trace to:
     https://github.com/phpstan/phpstan/issues/new?template=Bug_report.md
     Child process error (exit code 1):

https://github.com/composer/packagist/blob/e3f76f42980e6477e453f13526e33ed174318ff2/src/Command/IndexPackagesCommand.php#L292-L311

It seems to be due to the Connection::PARAM_INT_ARRAY usage, and the fact that one of the parameters is an array, which I assume this lib isn't expecting yet.

Activity

  1. staabm commented on Jan 19, 2022

    @staabm
    Owner

    #152 Fixed some array handling today..

    Which version of phpstan-dba do you work with?

  2. Seldaek commented on Jan 19, 2022

    @Seldaek
    ContributorAuthor

    0.2.1

  3. staabm commented on Jan 19, 2022

    @staabm
    Owner

    Reproduced in #158

    will need some handling for generic array. The fix from #152 only worked for constant arrays.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

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