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

Disable deprecation warnings when running in production envs #2375

Merged

Conversation

acelaya
Copy link
Member

@acelaya acelaya commented Feb 21, 2025

Closes #2373

Enable error reporting for any kind of error in dev and test envs, but disable reporting of deprecation warnings in production.

This is needed because the ProblemDetailsMiddleware wraps the whole execution in an error handler which converts any reported error into an ErrorException. See https://github.com/mezzio/mezzio-problem-details/blob/68a17a0/src/ProblemDetailsMiddleware.php#L101-L118

It is good to know about deprecation warnings when in dev, as those need to be eventually fixed, but in production, they should not cause the whole request to fail.

Todo

Sorry, something went wrong.

Copy link

codecov bot commented Feb 21, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 93.87%. Comparing base (449a588) to head (a18360a).
Report is 3 commits behind head on develop.

Additional details and impacted files
@@            Coverage Diff             @@
##             develop    #2375   +/-   ##
==========================================
  Coverage      93.87%   93.87%           
  Complexity      1707     1707           
==========================================
  Files            277      277           
  Lines           5915     5915           
==========================================
  Hits            5553     5553           
  Misses           362      362           

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@acelaya acelaya marked this pull request as ready for review February 21, 2025 20:17
@acelaya acelaya merged commit 5eb14c5 into shlinkio:develop Feb 21, 2025
23 checks passed
@acelaya acelaya deleted the feature/deprecation-error-reporting branch February 21, 2025 20:18
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

Successfully merging this pull request may close these issues.

Shlink 4.4.4 failing to acquire lock with Redis cluster when TLS connection to the Redis cluster is enabled
1 participant