Skip to content

Commit c94cd51

Browse files
docs: fix warning filter for v1 deprecations (#3337) (#3339)
Co-authored-by: Brett Langdon <[email protected]> Co-authored-by: Brett Langdon <[email protected]> (cherry picked from commit 5486e1a) Co-authored-by: Tahir H. Butt <[email protected]>
1 parent a7e13de commit c94cd51

File tree

2 files changed

+9
-3
lines changed

2 files changed

+9
-3
lines changed

releasenotes/notes/release-1.0-758fc917e40d7eb3.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,10 +18,10 @@ prelude: >
1818
1919
2020
.. note::
21-
Before upgrading to v1.0.0, we recommend running tests with `warning filters <https://docs.python.org/3.8/library/warnings.html#warning-filter>`_ set to turning warnings into exceptions. For example::
21+
Before upgrading to v1.0.0, we recommend installing ``ddtrace>=0.59.0,<1.0.0`` and running tests with `warning filters <https://docs.python.org/3.8/library/warnings.html#warning-filter>`_ set to raise ``ddtrace.warnings.DDTraceV1DeprecationWarning`` as errors or set the environment variable ``DD_TRACE_RAISE_DEPRECATIONWARNING``. For example::
2222
23-
$ PYTHONWARNINGS="error::DeprecationWarning:ddtrace[.*]" python tests.py
24-
$ pytest -W="error::DeprecationWarning:ddtrace[.*]" tests.py
23+
$ DD_TRACE_RAISE_DEPRECATIONWARNING=1 python tests.py
24+
$ pytest -W "error::ddtrace.warnings.DDTraceDeprecationWarning" tests.py
2525
2626
Once all deprecation warnings are addressed you can safely upgrade to v1.0.0.
2727
Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
upgrade:
3+
- |
4+
``ddtrace.warnings.DDTraceDeprecationWarning`` is removed.
5+
- |
6+
``DD_TRACE_RAISE_DEPRECATIONWARNING`` environment variable is removed.

0 commit comments

Comments
 (0)