Skip to content

Commit

Permalink
Added asgiref depedency to opentelemetry-instrumentation-asgi
Browse files Browse the repository at this point in the history
opentelemetry-instrumentaiton-asgi does not contain an instrumentor for
asgiref. Instead, it implements an ASGI middleware that other
instrumentors import and use. As such, other instrumentors can take a
dependency on this package without asgiref being installed locally. This
commit adds `asgiref` as a dependency to the
opentelemetry-instrumentation-asgi package so the middleware can
function properly when used by another instrumentation.
  • Loading branch information
owais committed Oct 20, 2021
1 parent c24c77d commit 6ea107e
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 6 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [Unreleased](https://github.com/open-telemetry/opentelemetry-python/compare/v1.6.2-0.25b2...HEAD)
### Fixed

- `opentelemetry-instrumentation-asgi` now explicitly depends on asgiref as it uses the package instead of instrumenting it.
([#765](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/765))

## [1.6.2-0.25b2](https://github.com/open-telemetry/opentelemetry-python/releases/tag/v1.6.2-0.25b2) - 2021-10-19

Expand Down
2 changes: 1 addition & 1 deletion instrumentation/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
| --------------- | ------------------ |
| [opentelemetry-instrumentation-aiohttp-client](./opentelemetry-instrumentation-aiohttp-client) | aiohttp ~= 3.0 |
| [opentelemetry-instrumentation-aiopg](./opentelemetry-instrumentation-aiopg) | aiopg >= 0.13.0, < 1.3.0 |
| [opentelemetry-instrumentation-asgi](./opentelemetry-instrumentation-asgi) | asgiref ~= 3.0 |
| [opentelemetry-instrumentation-asgi](./opentelemetry-instrumentation-asgi) | asgi |
| [opentelemetry-instrumentation-asyncpg](./opentelemetry-instrumentation-asyncpg) | asyncpg >= 0.12.0 |
| [opentelemetry-instrumentation-boto](./opentelemetry-instrumentation-boto) | boto~=2.0 |
| [opentelemetry-instrumentation-botocore](./opentelemetry-instrumentation-botocore) | botocore ~= 1.0 |
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,6 +43,7 @@ install_requires =
opentelemetry-semantic-conventions == 0.25b2
opentelemetry-instrumentation == 0.25b2
opentelemetry-util-http == 0.25b2
asgiref ~= 3.0

[options.extras_require]
test =
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,4 +13,4 @@
# limitations under the License.


_instruments = ("asgiref ~= 3.0",)
_instruments = tuple()
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,6 @@
"library": "aiopg >= 0.13.0, < 1.3.0",
"instrumentation": "opentelemetry-instrumentation-aiopg==0.25b2",
},
"asgiref": {
"library": "asgiref ~= 3.0",
"instrumentation": "opentelemetry-instrumentation-asgi==0.25b2",
},
"asyncpg": {
"library": "asyncpg >= 0.12.0",
"instrumentation": "opentelemetry-instrumentation-asyncpg==0.25b2",
Expand Down Expand Up @@ -134,6 +130,7 @@
},
}
default_instrumentations = [
"opentelemetry-instrumentation-asgi==0.25b2",
"opentelemetry-instrumentation-dbapi==0.25b2",
"opentelemetry-instrumentation-logging==0.25b2",
"opentelemetry-instrumentation-sqlite3==0.25b2",
Expand Down

0 comments on commit 6ea107e

Please sign in to comment.