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

psr/log update in server/3rdparty broke ci for master #10236

Closed
kesselb opened this issue Oct 8, 2024 · 1 comment · Fixed by #10237
Closed

psr/log update in server/3rdparty broke ci for master #10236

kesselb opened this issue Oct 8, 2024 · 1 comment · Fixed by #10237
Assignees

Comments

@kesselb
Copy link
Contributor

kesselb commented Oct 8, 2024

Steps to reproduce

  1. Run CI against master
  2. 💥

Actual behavior

PHP Fatal error: Declaration of Psr\Log\AbstractLogger::emergency($message, array $context = []) must be compatible with Psr\Log\LoggerInterface::emergency(Stringable|string $message, array $context = []): void in /home/runner/actions-runner/_work/mail/mail/nextcloud/apps/mail/vendor/psr/log/Psr/Log/AbstractLogger.php on line 22

Additional info

Solution 1: Update psr/log to 3.0.2

#10237

Good: Package matches the version in 3rdparty
Bad: The version in stable29 and stable30 is still psr/log 1.x.

Solution 2: Remove psr/log

#10235

The package is bundled with nextcloud, and therefore it's actually wrong to have it here. We can utilize the composer replace function, but that's also tricky.

For example, we need stubs for the logger interfaces otherwise psalm is not happy. Installing the package temporary (like we do with nextcloud/ocp) does not work because of the replace definition.

@the-djmaze
Copy link

the-djmaze commented Oct 8, 2024

Just a heads-up:

Image

Taken from https://xkcd.com/927/

@st3iny st3iny linked a pull request Oct 9, 2024 that will close this issue
1 task
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants