Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[PHP 8.4 support] and thecodingmachine/safe package #1423

Open
llaville opened this issue Nov 15, 2024 · 2 comments
Open

[PHP 8.4 support] and thecodingmachine/safe package #1423

llaville opened this issue Nov 15, 2024 · 2 comments

Comments

@llaville
Copy link
Contributor

Hello @theofidry

Did you have in mind to replace the thecodingmachine/safe package that did not support PHP 8.4 runtime (lot of dreprecations raised)

Latest version 2.5.0 is very old and project seems dead (no activity since at least one year)

Trying to compile a project with BOX 4.6.2 today on PHP 8.4.0RC4 platform and got masses of dreprecations, and have no PHAR built !


Deprecated: _HumbugBoxc5dcacdc09f0\Safe\gmdate(): Implicitly marking parameter $timestamp as nullable is deprecated, the explicit nullable type must be used instead in phar:///shared/backups/php/box-4.6.phar/vendor/thecodingmachine/safe/deprecated/datetime.php on line 6

Deprecated: _HumbugBoxc5dcacdc09f0\Safe\mktime(): Implicitly marking parameter $minute as nullable is deprecated, the explicit nullable type must be used instead in phar:///shared/backups/php/box-4.6.phar/vendor/thecodingmachine/safe/deprecated/datetime.php on line 19


< ... much more not displayed here : GitHub issue reporting body reach limit 65536 bytes) ...>

Deprecated: _HumbugBoxc5dcacdc09f0\Amp\Socket\Internal\normalizeBindToOption(): Implicitly marking parameter $bindTo as nullable is deprecated, the explicit nullable type must be used instead in phar:///shared/backups/php/box-4.6.phar/vendor/amphp/socket/src/Internal/functions.php on line 129

In Preg.php line 78:

  _HumbugBoxc5dcacdc09f0\Composer\Pcre\Preg::replace(): Implicitly marking parameter $count as nullable is deprecated, the explicit nullable
  type must be used instead

@llaville
Copy link
Contributor Author

Of course there is a workaround to build the PHAR with following command line (removing deprecations display) :

php -d error_reporting=24575 vendor/bin/box compile

@llaville
Copy link
Contributor Author

Other BOX commands are impacted, and info is unusable :

In PharInfo.php line 192:

  The command "'/usr/local/bin/php' '/shared/backups/php/box-4.6.phar' 'extract' '/shared/backups/bartlett/graph-uml/graph-uml.phar' '/tmp/Hu
  mbugBox/Pharaoh17771' '--no-interaction' '--internal'" failed.

  Exit Code: 1(General error)

  Working directory: /shared/backups/bartlett/graph-uml

  Output:
  ================

  Deprecated: _HumbugBoxc5dcacdc09f0\Safe\gmdate(): Implicitly marking parameter $timestamp as nullable is deprecated, the explicit nullable
  type must be used instead in phar:///shared/backups/php/box-4.6.phar/vendor/thecodingmachine/safe/deprecated/datetime.php on line 6


  < ... much more deprecations displayed hidden here ...>
  
  
  Deprecated: _HumbugBoxc5dcacdc09f0\Amp\Socket\Internal\normalizeBindToOption(): Implicitly marking parameter $bindTo as nullable is depreca
  ted, the explicit nullable type must be used instead in phar:///shared/backups/php/box-4.6.phar/vendor/amphp/socket/src/Internal/functions.
  php on line 129


  Error Output:
  ================

  In Preg.php line 78:

    _HumbugBoxc5dcacdc09f0\Composer\Pcre\Preg::replace(): Implicitly marking pa
    rameter $count as nullable is deprecated, the explicit nullable type must b
    e used instead


  extract [--internal] [--] <phar> <output>
 

Context is : PHP 8.4.0RC4, Box 4.6.2 and dreprecations not reported after building a PHAR version of my project https://github.com/llaville/graph-uml (source code on branch 1.6 coming soon online)

php -d error_reporting=24575 /shared/backups/php/box-4.6.phar info ./graph-uml.phar

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant