Installing the latest version

Created on 13 February 2023, almost 2 years ago
Updated 22 February 2024, 10 months ago

I'm running Drupal 9.5.3 on PHP 8.1.15 and used the instructions on the module's home page to install. It ended up installing version 8.3.11. It seems to be working except for every scan shows PHPstan errors so large I can't post them here. Reading the comments it sound like a lot of the was fixed by the current version, however when I try to install the upgrade directly I get:

  Problem 1
    - Root composer.json requires drupal/upgrade_status ^3.18 -> satisfiable by drupal/upgrade_status[3.18.0, 3.x-dev].
    - drupal/upgrade_status[3.18.0, ..., 3.x-dev] require mglaman/phpstan-drupal ^1.0.0 -> found mglaman/phpstan-drupal[dev-main, 1.0.0, ..., 1.1.29] but the package is fixed to 0.12.15 (lock file version) by a partial update and that version does not match. Make sure you list it as an argument for the update command.

Use the option --with-all-dependencies (-W) to allow upgrades, downgrades and removals for packages currently locked to specific versions.

Is there a way for me to upgrade? Will it remove at least some of the PHPstan errors?

πŸ’¬ Support request
Status

Closed: works as designed

Version

3.11

Component

Upgrade Assist

Created by

πŸ‡ΊπŸ‡ΈUnited States wxman

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

Comments & Activities

  • Issue created by @wxman
  • Status changed to Postponed: needs info almost 2 years ago
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Did you try the --with-all-dependencies (-W) as suggested by composer to update the locked dependency?

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    Yes I did

  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Did that resolve the problem or does the phpstan problem persist?

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    It's still there. I scanned a small module I mad and here's the whole output

    
    PHPStan command failed:
    
    /opt/plesk/php/8.1/bin/php /var/www/vhosts/site.com/newsite/vendor/bin/phpstan analyse --memory-limit=-1 --error-format=json --configuration=/var/www/vhosts/site.com/tmp/upgrade_status/deprecation_testing.neon /var/www/vhosts/site.com/newsite/web/modules/custom/amazonlink
    Command output:
    
    Empty.
    Command error:
    
    PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedPropertyNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedPropertyNode.php on line 71 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedPropertyNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedPropertyNode.php on line 71 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedInterfaceNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedInterfaceNode.php on line 56 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedInterfaceNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedInterfaceNode.php on line 56 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedPhpDocNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedPhpDocNode.php on line 37 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedPhpDocNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedPhpDocNode.php on line 37 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedFunctionNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedFunctionNode.php on line 73 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedFunctionNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedFunctionNode.php on line 73 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedClassNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedClassNode.php on line 85 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedClassNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedClassNode.php on line 85 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedTraitUseAdaptation::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedTraitUseAdaptation.php on line 75 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedTraitUseAdaptation::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedTraitUseAdaptation.php on line 75 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedParameterNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedParameterNode.php on line 46 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedParameterNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedParameterNode.php on line 46 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedMethodNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedMethodNode.php on line 93 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedMethodNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedMethodNode.php on line 93 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedTraitNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedTraitNode.php on line 39 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedTraitNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedTraitNode.php on line 39 PHP Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedClassConstantNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedClassConstantNode.php on line 68 Deprecated: Return type of PHPStan\Dependency\ExportedNode\ExportedClassConstantNode::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Dependency/ExportedNode/ExportedClassConstantNode.php on line 68 PHP Deprecated: Return type of PHPStan\Analyser\Error::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Analyser/Error.php on line 137 Deprecated: Return type of PHPStan\Analyser\Error::jsonSerialize() should either be compatible with JsonSerializable::jsonSerialize(): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/src/Analyser/Error.php on line 137 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Console\Helper\HelperSet::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/console/Helper/HelperSet.php on line 92 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Console\Helper\HelperSet::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/console/Helper/HelperSet.php on line 92 PHP Deprecated: Return type of Hoa\Protocol\Node\Node::offsetExists($name) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 134 Deprecated: Return type of Hoa\Protocol\Node\Node::offsetExists($name) should either be compatible with ArrayAccess::offsetExists(mixed $offset): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 134 PHP Deprecated: Return type of Hoa\Protocol\Node\Node::offsetGet($name) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 121 Deprecated: Return type of Hoa\Protocol\Node\Node::offsetGet($name) should either be compatible with ArrayAccess::offsetGet(mixed $offset): mixed, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 121 PHP Deprecated: Return type of Hoa\Protocol\Node\Node::offsetSet($name, $node) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 100 Deprecated: Return type of Hoa\Protocol\Node\Node::offsetSet($name, $node) should either be compatible with ArrayAccess::offsetSet(mixed $offset, mixed $value): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 100 PHP Deprecated: Return type of Hoa\Protocol\Node\Node::offsetUnset($name) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 144 Deprecated: Return type of Hoa\Protocol\Node\Node::offsetUnset($name) should either be compatible with ArrayAccess::offsetUnset(mixed $offset): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 144 PHP Deprecated: Return type of Hoa\Protocol\Node\Node::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 301 Deprecated: Return type of Hoa\Protocol\Node\Node::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/hoa/protocol/Node/Node.php on line 301 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Finder::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Finder.php on line 556 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Finder::getIterator() should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Finder.php on line 556 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Finder::count() should either be compatible with Countable::count(). Deprecated int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Finder.php on line 618 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Finder::count() should either be compatible with Countable::count(). Deprecated int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Finder.php on line 618 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\FileTypeFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/FileTypeFilterIterator.php on line 37 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\FileTypeFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/FileTypeFilterIterator.php on line 37 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::getChildren() should either be compatible with RecursiveDirectoryIterator::getChildren(): RecursiveDirectoryIterator, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 74 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::getChildren() should either be compatible with RecursiveDirectoryIterator::getChildren(): RecursiveDirectoryIterator, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 74 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::rewind() should either be compatible with FilesystemIterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 98 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::rewind() should either be compatible with FilesystemIterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 98 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::current() should either be compatible with FilesystemIterator::current(): SplFileInfo|FilesystemIterator|string, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 54 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\RecursiveDirectoryIterator::current() should either be compatible with FilesystemIterator::current(): SplFileInfo|FilesystemIterator|string, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 54 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 51 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 51 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::hasChildren() should either be compatible with RecursiveIterator::hasChildren(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 66 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::hasChildren() should either be compatible with RecursiveIterator::hasChildren(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 66 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::getChildren() should either be compatible with RecursiveIterator::getChildren(): ?RecursiveIterator, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 70 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\ExcludeDirectoryFilterIterator::getChildren() should either be compatible with RecursiveIterator::getChildren(): ?RecursiveIterator, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/ExcludeDirectoryFilterIterator.php on line 70 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\FilenameFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/FilenameFilterIterator.php on line 26 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\FilenameFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/FilenameFilterIterator.php on line 26 PHP Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\PathFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/PathFilterIterator.php on line 26 Deprecated: Return type of _PHPStan_76800bfb5\Symfony\Component\Finder\Iterator\PathFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar:///var/www/vhosts/site.com/newsite/vendor/phpstan/phpstan/phpstan.phar/vendor/symfony/finder/Iterator/PathFilterIterator.php on line 26 Error thrown in /var/www/vhosts/site.com/newsite/vendor/mglaman/phpstan-drupal/src/Drupal/DrupalAutoloader.php on line 190 while loading bootstrap file /var/www/vhosts/site.com/newsite/vendor/mglaman/phpstan-drupal/drupal-autoloader.php: Cannot unset string offsets
    
    
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary

    Which versions of phpstan and phpstan-drupal did you end up with that still produces this error? Thanks!

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    I can't seem to find how to check the version. I thought it was just phpstan -V. All I get is a lot of errors.

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    Just ran updates for everything again, and once again tried to install v3.18

    composer require 'drupal/upgrade_status:^3.18' --with-all-dependencies

    
      Problem 1
        - mglaman/phpstan-drupal[1.0.0, ..., 1.1.16] require phpstan/phpstan ^1.0 -> found phpstan/phpstan[1.0.0, ..., 1.10.x-dev] but these were not loaded, likely because it conflicts with another require.
        - mglaman/phpstan-drupal[1.1.17, ..., 1.1.20] require phpstan/phpstan ^1.7.0 -> found phpstan/phpstan[1.7.0, ..., 1.10.x-dev] but these were not loaded, likely because it conflicts with another require.
        - mglaman/phpstan-drupal[1.1.21, ..., 1.1.25] require phpstan/phpstan ^1.6.0 -> found phpstan/phpstan[1.6.0, ..., 1.10.x-dev] but these were not loaded, likely because it conflicts with another require.
        - mglaman/phpstan-drupal[1.0.x-dev, ..., 1.1.29] require phpstan/phpstan ^1.9.0 -> found phpstan/phpstan[1.9.0, ..., 1.10.x-dev] but these were not loaded, likely because it conflicts with another require.
        - drupal/upgrade_status[3.18.0, ..., 3.x-dev] require mglaman/phpstan-drupal ^1.0.0 -> satisfiable by mglaman/phpstan-drupal[1.0.0, ..., 1.1.29].
        - Root composer.json requires drupal/upgrade_status ^3.18 -> satisfiable by drupal/upgrade_status[3.18.0, 3.x-dev].
    
  • πŸ‡¦πŸ‡ΊAustralia dpi Perth, Australia

    Either remove phpstan/phpstan from your composer.json (because its going to be required by this project), or if you're using PHPStan in your project then require any version 1. As in change "^0.12.60" -> "^1"

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    I'm not trying to sound ignorant, but phpstan/phpstan is not in my site's composer.json. I found it in my composer.lock though:

                "require-dev": {
                    "composer/composer": "1.6.* || ^2.0",
                    "composer/semver": "^1 || ^3",
                    "phpstan/phpstan": "^0.12.55",
                    "phpstan/phpstan-phpunit": "^0.12.16",
                    "symfony/phpunit-bridge": "^4.2 || ^5",
                    "symfony/process": "^2.3"
                },
    
  • πŸ‡¦πŸ‡ΊAustralia dpi Perth, Australia

    Yeah I read 8 as root json file.

    Something seems to be keeping phpstan on a v0 release though? Your lock file entry for phpstan is a v0?

    If this is true, my only further suggestion is a composer why-not phpstan/phpstan 1.9.17 to see whats holding you back.

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    Okay I tried the suggestion and here is what got barfed out:

    $ composer why-not phpstan/phpstan 1.9.17
    Info from https://repo.packagist.org: #StandWithUkraine
    mglaman/phpstan-drupal            0.12.15 requires phpstan/phpstan (^0.12.65)
    phpstan/phpstan-deprecation-rules 0.12.6  requires phpstan/phpstan (^0.12.60)
    rector/rector                     0.11.60 requires phpstan/phpstan (0.12.99)
    Not finding what you were looking for? Try calling `composer update "phpstan/phpstan:1.9.17" --dry-run` to get another view on the problem.
    
    $ composer update phpstan/phpstan:1.9.17 --dry-run
    Loading composer repositories with package information                                                                                   Updating dependencies
    Your requirements could not be resolved to an installable set of packages.
    
      Problem 1
        - mglaman/phpstan-drupal 0.12.15 requires phpstan/phpstan ^0.12.65 -> found phpstan/phpstan[0.12.65, ..., 0.12.x-dev] but it conflicts with your temporary update constraint (phpstan/phpstan:1.9.17).
        - drupal/upgrade_status 3.11.0 requires mglaman/phpstan-drupal ^0.12.12 -> satisfiable by mglaman/phpstan-drupal[0.12.15].
        - drupal/upgrade_status is locked to version 3.11.0 and an update of this package was not requested.
    
    
  • πŸ‡³πŸ‡ΏNew Zealand jonathan_hunt

    I had a similar situation. In my case rector/rector was holding phpstan back "rector/rector 0.11.60 requires phpstan/phpstan (0.12.99)". Rector was required by dev palantirnet/drupal-rector. composer remove --dev palantirnet/drupal-rector removed old dependencies and allowed composer require drupal/upgrade_status -W to succeed.

  • πŸ‡ΊπŸ‡ΈUnited States wxman

    Thank you jonathan_hunt! #13 did the trick.

    composer remove --dev palantirnet/drupal-rector
     
    composer require drupal/upgrade_status -W
    

    It upgraded to the latest version, and now scans with no errors.

  • Status changed to Closed: works as designed 10 months ago
  • πŸ‡­πŸ‡ΊHungary GΓ‘bor Hojtsy Hungary
Production build 0.71.5 2024