Visitar URL original
SPX install.sh reports failure when default PHP is 8.5+, though the install worked for 8.2–8.4 · Issue #1788 · beyondcode/herd-community · GitHub
Skip to content

SPX install.sh reports failure when default PHP is 8.5+, though the install worked for 8.2–8.4 #1788

Open
beyondcode/php-spx
#3

Description

@percymamedy

Description

When Herd's default PHP is 8.5, running the installer ends with an error, even though SPX installed correctly for every supported version.

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/beyondcode/php-spx/HEAD/install.sh)"

 INFO  Latest release: 0.4.17
 INFO  Installing the SPX Profiler extension...
 INFO  Laravel Herd is installed. Installing for all available PHP versions...
 INFO  Restarting Laravel Herd...
 ERROR  There was an error installing the extension.
 ERROR  Please check the output above for any errors.

Environment

  • macOS (arm64), Laravel Herd
  • Installed PHP versions: 8.2, 8.3, 8.4, 8.5, 8.6
  • Default php: 8.5.12
  • SPX release: 0.4.17

Cause

  1. The install loop is hardcoded to for version in {74..84}, so it skips 8.5 and 8.6.
  2. Release 0.4.17 has no spx-php-8.5-* or spx-php-8.6-* macOS builds.
  3. The final check runs php -m | grep SPX against the default PHP (8.5). SPX isn't there, so the script reports failure.

Checked after running: php82 -m, php83 -m and php84 -m all list SPX.

Expected

  • Builds for PHP 8.5 and 8.6, plus a wider loop range (or a loop over whatever php* binaries Herd has installed).
  • If those can't ship yet, the script should say "PHP 8.5 not supported yet, installed for 8.2, 8.3, 8.4" instead of a general error. It could do that by checking each installed version rather than only the default php.
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

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions