aaemnnosttv / wp-cli-login-command

Log in to WordPress with secure passwordless magic links.
https://aaemnnost.tv/wp-cli-commands/login/
MIT License
292 stars 47 forks source link

Not compatible with PHP 8.3.1 #76

Closed Lovor01 closed 2 weeks ago

Lovor01 commented 3 weeks ago

I use PHP 8.3.1 on CLI and when tried to install this package I got a lot of deprecation messages and notice that installation failed.

aaemnnosttv commented 3 weeks ago

Thanks, can you share the output here so we can see specifically what you're getting?

Lovor01 commented 3 weeks ago

After further review, it seems to me that installation might fail because of insufficient rights (in the instructions how to install on github nowhere is written you have to have elevated rights), but those deprecations listed are surely not because of lower rights.

Installing package aaemnnosttv/wp-cli-login-command (dev-main || dev-master || dev-trunk)
Updating C:\Users\generic\.wp-cli\packages\composer.json to require the package...
Using Composer to install the package...
---
Loading composer repositories with package information
Found 116 package versions referenced in your dependency graph. 32 (28%) were optimized away.
Updating dependencies
Generating rules
Resolving dependencies through SAT
Looking at all rules.
Something's changed, looking at all rules again (pass #1)

Dependency resolution completed in 0.001 seconds
Analyzed 84 packages to resolve dependencies
Analyzed 88 rules to resolve dependencies
Lock file operations: 2 installs, 0 updates, 0 removals
Installs: composer/semver:3.4.0, aaemnnosttv/wp-cli-login-command:dev-master ab20aee
- Locking aaemnnosttv/wp-cli-login-command (dev-master ab20aee)
- Locking composer/semver (3.4.0)
Writing lock file
Installing dependencies from lock file
Package operations: 2 installs, 0 updates, 0 removals
Installs: composer/semver:3.4.0, aaemnnosttv/wp-cli-login-command:dev-master ab20aee
PHP Deprecated:  Return type of Symfony\Component\Process\Process::getIterator($flags = 0) should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/process/Process.php on line 567        

Deprecated: Return type of Symfony\Component\Process\Process::getIterator($flags = 0) should either be compatible with IteratorAggregate::getIterator(): Traversable, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/process/Process.php on line 567
 - Installing <info>composer/semver</info> (<comment>3.4.0</comment>)
PHP Deprecated:  Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Finder.php on line 566

Deprecated: Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Finder.php on line 566
PHP Deprecated:  Return type of Symfony\Component\Finder\Finder::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Finder.php on line 637

Deprecated: Return type of Symfony\Component\Finder\Finder::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Finder.php on line 637
PHP Deprecated:  Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 89

Deprecated: Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 89
PHP Deprecated:  Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 117

Deprecated: Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 117
PHP Deprecated:  Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 65

Deprecated: Return type of 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://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/RecursiveDirectoryIterator.php on line 65
PHP Deprecated:  Return type of Symfony\Component\Finder\Iterator\FilterIterator::rewind() should either be compatible with FilterIterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/FilterIterator.php on line 32

Deprecated: Return type of Symfony\Component\Finder\Iterator\FilterIterator::rewind() should either be compatible with FilterIterator::rewind(): void, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/FilterIterator.php on line 32
PHP Deprecated:  Return type of Symfony\Component\Finder\Iterator\DepthRangeFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/DepthRangeFilterIterator.php on line 41

Deprecated: Return type of Symfony\Component\Finder\Iterator\DepthRangeFilterIterator::accept() should either be compatible with FilterIterator::accept(): bool, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in phar://C:/Wamp.NET/tools/wp-cli/wp-cli.phar/vendor/symfony/finder/Iterator/DepthRangeFilterIterator.php on line 41
 - Installing <info>aaemnnosttv/wp-cli-login-command</info> (<comment>dev-master ab20aee</comment>)
Warning: Failed to clone https://github.com/composer/semver.git via https, ssh protocols, aborting.

- https://github.com/composer/semver.git
  Cloning into 'C:\Users\generic\.wp-cli\packages\vendor\composer\semver'...
  git-upload-pack 'C:/Users/generic/AppData/Local/Composer/vcs/https---github.com-composer-semver.git/': line 1: git-upload-pack: command not found
  fatal: Could not read from remote repository.

  Please make sure you have the correct access rights
  and the repository exists.

- git@github.com:composer/semver.git
  Cloning into 'C:\Users\generic\.wp-cli\packages\vendor\composer\semver'...
  git-upload-pack 'C:/Users/generic/AppData/Local/Composer/vcs/https---github.com-composer-semver.git/': line 1: git-upload-pack: command not found
  fatal: Could not read from remote repository.

  Please make sure you have the correct access rights
  and the repository exists.

---
Error: Package installation failed.
Reverted composer.json.
aaemnnosttv commented 3 weeks ago

Thanks for the context, that is very helpful.

The deprecation notices you are seeing during installation are not from the login command (the notices indicate Symfony components but the command's only dependency is composer/semver which has no dependencies of its own); the package itself wouldn't be loaded yet. My guess is that you may be using an older version of wp-cli (check with wp cli check-update, update with wp cli update) and that the output you're seeing would probably happen with any package.

it seems to me that installation might fail because of insufficient rights (in the instructions how to install on github nowhere is written you have to have elevated rights), but those deprecations listed are surely not because of lower rights.

The main problem I see which is causing the install to fail is git-upload-pack: command not found.