chore(profiling-315): collectors and py3.15 CI matrix - #19270
chore(profiling-315): collectors and py3.15 CI matrix#19270vlad-scherbich wants to merge 4 commits into
Conversation
|
9a117a3 to
188e8e1
Compare
7d3e825 to
9ef0d6d
Compare
188e8e1 to
e6e1f72
Compare
9ef0d6d to
6f9a44c
Compare
Circular import analysis
|
Codeowners resolved asResolved from the full PR diff against |
Dependency direction analysis
|
6f9a44c to
ee28a3f
Compare
e6e1f72 to
0fb56d5
Compare
BenchmarksBenchmark execution time: 2026-08-28 19:10:23 Comparing candidate commit 47ff18b in PR branch Found 0 performance improvements and 7 performance regressions! Performance is the same for 579 metrics, 10 unstable metrics, 3 known flaky benchmarks, 15 flaky benchmarks without significant changes.
|
b2cdb77 to
2d20a3c
Compare
ee28a3f to
b7a93de
Compare
2d20a3c to
29f2a6e
Compare
b7a93de to
c3ee47f
Compare
There was a problem hiding this comment.
Pull request overview
Updates profiling collectors and CI/build wiring to better support Python 3.15, including making collector imports resilient when profiling Cython extensions are not present and extending the riot/CI matrices and lockfiles to exercise 3.15.
Changes:
- Add ImportError fallbacks/stubs for profiling collectors that depend on Cython extensions (
_lock,_task,_exception) so profiling can be imported and collectors can be gracefully skipped when extensions aren’t available. - Update
setup.pygating and environment to allow building profiling/crashtracker natives on Python 3.15 (incl. PyO3 ABI3 forward-compat safety net). - Extend riot/lockfiles and CI configuration to include Python 3.15 coverage for relevant suites/jobs.
Reviewed changes
Copilot reviewed 17 out of 17 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/profiling/test_scheduler.py | Stabilizes scheduler logging test by patching upload and adds type hints. |
| setup.py | Enables profiling-related native builds through 3.15 and sets PyO3 ABI3 forward-compat env var on 3.15+. |
| scripts/requirements_to_csv.py | Improves typing (untyped toml) and normalizes CSV line endings. |
| riotfile.py | Adds/selects 3.15 in specific venv definitions and updates a protobuf incompat comment. |
| ddtrace/profiling/collector/threading.py | Adds ImportError fallback stubs when _lock extension isn’t available. |
| ddtrace/profiling/collector/asyncio.py | Adds ImportError fallback stubs when _lock extension isn’t available. |
| ddtrace/profiling/collector/exception.py | Adds ImportError fallback stub for _exception extension. |
| ddtrace/profiling/collector/stack.py | Adds ImportError fallback stub for _task extension to keep StackCollector importable. |
| ddtrace/profiling/_asyncio.py | Adjusts task-linking wrappers to avoid failures when called outside a running loop. |
| ddtrace/internal/monitoring.py | Adds a guarded fallback when PY_UNWIND is rejected as a local monitoring event. |
| .riot/requirements/e26245b.txt | Adds a newly generated Python 3.15 lockfile. |
| .riot/requirements/95077af.txt | Adds a newly generated Python 3.15 lockfile. |
| .riot/requirements/222bcd0.txt | Adds a newly generated lockfile (currently contains merge-conflict markers). |
| .riot/requirements/1c6cb02.txt | Adds a newly generated Python 3.15 lockfile. |
| .gitlab/templates/build-base-venvs.yml | Extends artifact paths for profiling-native test outputs. |
| .gitlab-ci.yml | Adds an allow-failure profiling native job for Python 3.15 pending base-image support. |
| .github/workflows/generate-package-versions.yml | Adds Python 3.15 to the workflow’s installed Python set. |
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
| <<<<<<<< HEAD:.riot/requirements/222bcd0.txt | ||
| # pip-compile --allow-unsafe --no-annotate .riot/requirements/222bcd0.in | ||
| # | ||
| attrs==26.1.0 | ||
| cloudpickle==3.1.2 | ||
| coverage[toml]==7.14.3 | ||
| execnet==2.1.2 | ||
| gevent==26.5.0 | ||
| greenlet==3.5.3 | ||
| httpretty==1.1.4 | ||
| ======== | ||
| # pip-compile --allow-unsafe --no-annotate .riot/requirements/1857594.in | ||
| # | ||
| attrs==26.1.0 | ||
| coverage[toml]==7.13.5 | ||
| >>>>>>>> 49c1ffeaab (ci(profiling): wire py3.15 into build matrix, riotfile, and CI):.riot/requirements/1857594.txt |
| ], | ||
| ), | ||
| # Python 3.14 - protobuf 4.22.0 is not compatible (TypeError: Metaclasses with custom tp_new) | ||
| # Python 3.14+ - protobuf 4.22.0 is not compatible (TypeError: Metaclasses with custom tp_new) |
# Conflicts: # ddtrace/internal/monitoring.py # ddtrace/internal/wrapping/asyncs.py
Profiling-native py3.15 job, setup.py guards, and crashtracker 3.15 opt-in. Rebased onto the #17849 split stack (PR 17624). # Conflicts: # riotfile.py # setup.py
The collectors PR already claimed setup.py could build natives on 3.15, but rust profiling, libdd_wrapper, and memalloc/ddup/stack were still skipped below 3.15. Lift those bounds to match the Cython modules. Also stop attributing current_task() RuntimeError to 3.15.
29f2a6e to
717a251
Compare
c3ee47f to
47ff18b
Compare
prev: #19269 | next: #19272
Description
Delta vs #19269.
setup.pyraises the profiling / crashtracker / memalloc /_threadingbuild gates from< (3, 15)to< (3, 16), and setsPYO3_USE_ABI3_FORWARD_COMPATIBILITY=1on 3.15. Collectors (asyncio,exception,stack,threading) stub withCollectorUnavailableif the Cython extension is missing.profiling_native_py315is a separateallow_failurejob. Riot opt-in: crashtracker native 3.15 and grpc 3.15. GitHubsetup-python3.15 for package-version generation. asyncio gather/_wait wrappers catchRuntimeErrorfromcurrent_task()..riot/requirements/222bcd0.txtcontains unresolved git conflict markers.Does not add the sys.monitoring asyncio path (that's #19272).
Testing
Risks
Additional Notes
.riot/requirements/222bcd0.txtin this diff is conflicted. Nochangelog/no-changeloglabel on this PR.Contributes to #17817