Skip to content

Commit 71a14b7

Browse files
committed
feedback: Details in contributing doc
1 parent 919ca9c commit 71a14b7

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

CONTRIBUTING.md

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -329,7 +329,18 @@ Below is a checklist of things to be mindful of when implementing a new instrume
329329
- Update `_instruments` or `_instruments_any` variable in instrumentation **`package.py`** file with the new version constraint
330330
- At the **root of the project directory**, run `tox -e generate` to regenerate necessary files
331331

332-
Please note that `instruments-any` is an optional field that can be used instead of or in addition to `instruments`. While `instruments` is a list of dependencies, _all_ of which are expected by the instrumentation, `instruments-any` is a list _any_ of which but not all are expected.
332+
Please note that `instruments-any` is an optional field that can be used instead of or in addition to `instruments`. While `instruments` is a list of dependencies, _all_ of which are expected by the instrumentation, `instruments-any` is a list _any_ of which but not all are expected. For example, the following entry requires both `util` and `common` plus either `foo` or `bar` to be present for the instrumentation to occur:
333+
```
334+
[project.optional-dependencies]
335+
instruments = [
336+
"util ~= 1.0"
337+
"common ~= 2.0"
338+
]
339+
instruments-any = [
340+
"foo ~= 3.0"
341+
"bar ~= 4.0"
342+
]
343+
```
333344

334345
<!-- See https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3610 for details on instruments-any -->
335346

0 commit comments

Comments
 (0)