Conversation
- Read the sampling priority through get_sampling_priority() in the appsec payment, trace tagging and LLM endpoint tests: v1 carries it on the chunk. - Check span.kind on agent spans through get_span_kind() in the SQL tests: the agent reports it as a top-level enum in idxTracerPayloads. - Test_TraceHeaders, Test_Agent::test_agent_do_not_drop_traces and Test_SamplingDeterminism silently skipped /v1.0/traces payloads; make them format-agnostic so they cover v1 too.
Gate tests/test_v1_payloads.py on v1.26.0-dev, and keep Test_V1SpanLinks disabled: PHP creates no span link from conflicting contexts.
Contributor
|
|
❌ ErrorsYour PR has failed checks. Please review the issues below and take necessary action before merging. 🚦 67 Pipeline jobs failed
ℹ️ InfoNo other issues found (see more)❄️ No new flaky tests detected Useful? React with 👍 / 👎 This comment will be updated automatically if new data arrives.🔗 Commit SHA: 934eb96 | Docs | View more details | Give us feedback! |
Leiyks
added a commit
to DataDog/dd-trace-php
that referenced
this pull request
Sep 28, 2026
…merge Clone system-tests at SYSTEM_TESTS_REF (default leiyks/php-v1-payload, DataDog/system-tests#7843) from SYSTEM_TESTS_REPO, and add APM_TRACING_EFFICIENT_PAYLOAD to the System Tests matrix.
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Motivation
dd-trace-php is moving to the v1 (efficient) trace payload by default (DataDog/dd-trace-php#4046). Enabling the v1 tests for PHP surfaced a few assertions that only work with the v0.4 shape, and a few validators that silently skip
/v1.0/tracespayloads.Changes
manifests/php.yml: gatetests/test_v1_payloads.pyonv1.26.0-devinstead of a file-levelmissing_feature.Test_V1SpanLinksstaysmissing_feature, because PHP creates no span link from conflicting contexts (same asTest_Span_Links_From_Conflicting_Contexts)./add_event, which adds aspan.eventevent to the root span throughDDTrace\SpanEvent, like the Go weblogs.Test_V1SpanEventsneeds it.test_automated_payment_events.py,test_trace_tagging.pyandapi_security/test_endpoints.pyread_sampling_priority_v1from metrics. They now useget_sampling_priority(), because v1 carries the priority on the chunk.test_db_integrations_sql.py::test_span_kindnow checks agent spans withget_span_kind(). InidxTracerPayloads, the kind is a top-level enum (SPAN_KIND_CLIENT), not aspan.kindattribute.Test_TraceHeaders: the diagnostic-check, trace-count and container-id checks filtered on/v0.x/tracesonly. They now include/v1.0/traces, and count chunks there.Test_Agent::test_agent_do_not_drop_traceslooked for_sampling_priority_v1in span metrics and skipped every v1 trace.Test_SamplingDeterminismonly read/v0.4and/v0.5payloads.I replayed the PHP CI logs of a v1 branch build (DEFAULT and INTEGRATIONS). The payment events tests,
test_span_kindand the data integrity tests pass. Mutating the chunk count and the agent trace set madeTest_TraceHeadersandTest_Agentfail, which shows they now really check v1 payloads.Merge order
A master build and the v1 branch both report
1.26.0+dev.<sha>, so this version gate can't tell them apart. For that reason, this PR should land after (or together with) the dd-trace-php v1 change. If that change misses 1.26.0, the gate has to move to the next minor.Follow-ups (not in this PR)
NotImplementedErroron array attributes in v1 span and link attributes (_convert_v1_attributes,_convert_v1_span_link_attributes). This is out of scope here.tests/test_span_events.pyis stillincomplete_test_appfor PHP. Now that/add_eventexists, it can be evaluated.Test_Process_Tags,Test_Otel_SpanandTest_SingleSpanare disabled for PHP because process tags and_dd.top_levelare missing. PHP v1 payloads carry_dd.tags.process, so these need re-checking.