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

Add http.route tag to SymfonyIntegration.php #2992

Open
wants to merge 3 commits into
base: master
Choose a base branch
from

Conversation

cataphract
Copy link
Contributor

Description

Adds http.route to symfony. Supersedes #2710 and #2477

Reviewer checklist

  • Test coverage seems ok.
  • Appropriate labels assigned.

@cataphract cataphract requested review from a team as code owners December 12, 2024 02:26
@cataphract cataphract force-pushed the glopes/symfony-route branch 3 times, most recently from 93cec34 to 6a1adeb Compare December 12, 2024 02:30
@codecov-commenter
Copy link

codecov-commenter commented Dec 12, 2024

Codecov Report

Attention: Patch coverage is 0% with 43 lines in your changes missing coverage. Please review.

Project coverage is 55.97%. Comparing base (b928df9) to head (7233cec).
Report is 5 commits behind head on master.

Files with missing lines Patch % Lines
...DTrace/Integrations/Symfony/SymfonyIntegration.php 0.00% 43 Missing ⚠️

❗ There is a different number of reports uploaded between BASE (b928df9) and HEAD (7233cec). Click for more details.

HEAD has 1 upload less than BASE
Flag BASE (b928df9) HEAD (7233cec)
tracer-php 11 10
Additional details and impacted files

Impacted file tree graph

@@              Coverage Diff              @@
##             master    #2992       +/-   ##
=============================================
- Coverage     74.82%   55.97%   -18.85%     
- Complexity     2741     2745        +4     
=============================================
  Files           110      137       +27     
  Lines         10863    15015     +4152     
  Branches          0     1016     +1016     
=============================================
+ Hits           8128     8405      +277     
- Misses         2735     6058     +3323     
- Partials          0      552      +552     
Flag Coverage Δ
appsec-extension 67.84% <ø> (?)
tracer-php 51.49% <0.00%> (-23.33%) ⬇️

Flags with carried forward coverage won't be shown. Click here to find out more.

Files with missing lines Coverage Δ
...DTrace/Integrations/Symfony/SymfonyIntegration.php 0.00% <0.00%> (-82.86%) ⬇️

... and 46 files with indirect coverage changes


Continue to review full report in Codecov by Sentry.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b928df9...7233cec. Read the comment docs.

@pr-commenter
Copy link

pr-commenter bot commented Dec 12, 2024

Benchmarks [ tracer ]

Benchmark execution time: 2024-12-17 14:22:00

Comparing candidate commit 7233cec in PR branch glopes/symfony-route with baseline commit b928df9 in branch master.

Found 1 performance improvements and 0 performance regressions! Performance is the same for 177 metrics, 0 unstable metrics.

scenario:TraceFlushBench/benchFlushTrace

  • 🟩 execution_time [-1000.000ns; -1000.000ns] or [-50.000%; -50.000%]

@cataphract cataphract force-pushed the glopes/symfony-route branch 2 times, most recently from 1c181cf to 387a651 Compare December 12, 2024 14:41
Copy link

Snapshots difference summary

The following differences have been observed in committed snapshots. It is meant to help the reviewer.
The diff is simplistic, so please check some files anyway while we improve it.

If you need to update snapshots, please refer to CONTRIBUTING.md

@cataphract cataphract force-pushed the glopes/symfony-route branch 4 times, most recently from b09ad20 to 2c04437 Compare December 13, 2024 16:07
@cataphract cataphract force-pushed the glopes/symfony-route branch 2 times, most recently from 644c737 to ddbe994 Compare December 16, 2024 21:27
@@ -913,7 +913,6 @@ TEST_WEB_81 := \
test_web_nette_30 \
test_web_slim_312 \
test_web_slim_4 \
test_web_symfony_52 \
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are we removing those tests from PHP 8.1 up to PHP 8.3? 🤔

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Symfony 5.2 doesn't actually work with those PHP versions. The tests fail with:

[17-Dec-2024 19:40:57 -03] [ddtrace] [warning] Error raised in ddtrace's closure defined at /Users/gustavo.lopes/repos/dd-trace-php/src/DDTrace/Integrations/Symfony/SymfonyIntegration.php:394 for Symfony\Component\HttpKernel\HttpKernel::handle(): Return type of Symfony\Component\Routing\RouteCollection::count() should either be compatible with Countable::count(): int, or the #[\ReturnTypeWillChange] attribute should be used to temporarily suppress the notice in /Users/gustavo.lopes/repos/dd-trace-php/tests/Frameworks/Symfony/Version_5_2/vendor/symfony/routing/RouteCollection.php on line 69
 /Users/gustavo.lopes/repos/dd-trace-php/tests/Common/WebFrameworkTestCase.php:74
 /Users/gustavo.lopes/repos/dd-trace-php/tests/Common/MultiPHPUnitVersionAdapter_typed.php:33

Copy link
Contributor

@PROFeNoM PROFeNoM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

FYI, I can see the following warning/error from our CI: failure.

On a similar note, the Symfony 3.0 (:skull:) tests seems not to have the http.route tag: failure

@estringana
Copy link
Contributor

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.

5 participants