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

Update composer PHP depedencies #1101

Merged
merged 26 commits into from
Sep 13, 2024
Merged

Update composer PHP depedencies #1101

merged 26 commits into from
Sep 13, 2024

Conversation

melroy89
Copy link
Member

@melroy89 melroy89 commented Sep 9, 2024

  • First updated all minor versions
  • Updated PHPunit major version
  • Updated QR-code major version + fix PHP code
  • Upgraded JSON-schema
  • Removing laminas-diactoros (we don't use it)
  • Upgraded pagerfanta/core
  • Upgraded symfony/maker-bundle
  • Removing activitypub (we don't use it)
  • Upgraded doctrine-json-functions

I did not upgrade the following packages on purpose for now (packages have been kept back):

doctrine/orm                      2.19.7 3.2.2 Object-Relational-Mapper for PHP
furqansiddiqui/bip39-mnemonic-php 0.1.7  0.2.1 BIP39 Mnemonics implementation in PHP
league/oauth2-server-bundle       0.8.0  0.9.0 Symfony bundle .

doctrine/orm => Known to cause issues, so part of another follow-up PR. Just lessons learned from the past.
furqansiddiqui/bip39-mnemonic-php => Requires a new gmp PHP extension if we want to upgrade. I leave it out for now.
league/oauth2-server-bundle => Gives upgrade trouble: "league/oauth2-server 9.0.0 requires psr/http-message ^2.0 -> found psr/http-message[2.0] but these were not loaded, likely because it conflicts with another require"

@melroy89 melroy89 added dependencies Pull requests that update a dependency file php Pull requests that update PHP code labels Sep 9, 2024
@melroy89 melroy89 marked this pull request as ready for review September 9, 2024 19:28
@melroy89
Copy link
Member Author

melroy89 commented Sep 9, 2024

I have this branch running on my instance, without issues thus far.

@melroy89

This comment was marked as outdated.

@melroy89
Copy link
Member Author

melroy89 commented Sep 9, 2024

The qrcode upgrade seems to be the only issue thus far. Not showing me the image and the logging gave me:

{"message":"Uncaught PHP Exception Error: \"Class \"Endroid\\QrCode\\ErrorCorrectionLevel\\ErrorCorrectionLevelHigh\" not found\" at User2FAController.php line 133","context":{"exception":{"class":"Error","message":"Class \"Endroid\\QrCode\\ErrorCorrectionLevel\\ErrorCorrectionLevelHigh\" not found","code":0,"file":"/var/www/kbin.melroy.org/html/src/Controller/User/Profile/User2FAController.php:133"}},"level":500,"level_name":"CRITICAL","channel":"request","datetime":"2024-09-09T21:56:40.042112+02:00","extra":{}}

Apply the latest usage: https://github.com/endroid/qr-code?tab=readme-ov-file#usage-using-the-builder. Should be fixed now!

@melroy89
Copy link
Member Author

melroy89 commented Sep 9, 2024

With the latest pagerfanta/core you now also have auto pagination (we don't use it yet), just for info.

use Pagerfanta\Adapter\NullAdapter;
use Pagerfanta\Pagerfanta;

$pagerfanta = new Pagerfanta(new NullAdapter(100));
$pagerfanta->setMaxPerPage(10);

$iterator = $pagerfanta->autoPagingIterator();

@melroy89 melroy89 enabled auto-merge (squash) September 10, 2024 14:35
@melroy89
Copy link
Member Author

I'm now running this branch again at https://kbin.melroy.org

composer.json Outdated Show resolved Hide resolved
symfony.lock Show resolved Hide resolved
@melroy89 melroy89 added this to the v1.7.2 milestone Sep 12, 2024
@melroy89
Copy link
Member Author

I'm now running this branch again at https://kbin.melroy.org

Still runs fine here with laminas/laminas-diactoros removed.

symfony.lock Show resolved Hide resolved
@melroy89 melroy89 merged commit 36927bb into main Sep 13, 2024
7 checks passed
@melroy89 melroy89 deleted the update_php_deps branch September 13, 2024 10:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
dependencies Pull requests that update a dependency file php Pull requests that update PHP code
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants