2322 Commits

Author SHA1 Message Date
26bcc9347b SQLAlchemy: db.statement inclusion of sqlcomment as opt-in (#3112) 2025-01-09 12:56:14 -08:00
908437db5d click: ignore click based servers (#3174)
* click: ignore click based servers

We don't want to create a root span for long running processes like servers
otherwise all requests would have the same trace id which is unfortunate.
---------

Co-authored-by: Tammy Baylis <96076570+tammy-baylis-swi@users.noreply.github.com>
2025-01-09 11:29:31 +01:00
147e3f754e Add check before iterating over dist.requires at load_instrumentor (#3168)
* Add check before iterate over dist.requires

* Changelog

* Add test
2025-01-08 10:02:55 +01:00
3d5935f4f6 docs: add missing import to aws-lambda (#3154) 2025-01-02 12:18:07 -08:00
95f14cd8df wsgi: always record span status code to have it available in metrics (#3148) 2025-01-02 11:58:17 -08:00
e5eb524e89 Improve type hints in opentelemetry.instrumentation.utils (#3128) 2025-01-02 11:44:58 -08:00
3e394a4814 Support PEP 561 to opentelemetry-instrumentation-system-metrics (#3132) 2025-01-02 11:30:41 -08:00
16c041e22b Support PEP 561 to opentelemetry-instrumentation-sqlite3 (#3133) 2025-01-02 11:15:01 -08:00
54882871b9 add official support to Python 3.13 (#3134)
* add py313 to tox

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix wrong identation troveclassifiers

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix pyramid, django

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix httpx

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix httpx, grpc and add vertex

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* generate-workflows

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix generate-workflows

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix celery and psycopg

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* add changelog

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* Update CHANGELOG.md

* Update tox.ini

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-31 16:08:20 +00:00
c084ca8fa5 Update README.rst - Fix Markdown (#3156)
Fix broken Markdown.

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-31 16:31:33 +01:00
8db1479e0d RELEASING: Document what package prepare release workflows will create (#3153)
While at it fix formatting
2024-12-30 13:13:07 +00:00
72dc1cf1f6 prometheus-remote-write: bump cramjam to 2.8.4 in test-requirements (#3157)
Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-30 09:26:54 +01:00
16eaec8d03 cassandra: fix tests for py313 (#3152)
* cassandra: fix tests to make CI happy for py313

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* ruff

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-24 16:14:05 +01:00
d116ae39d6 Update opentelemetry-sdk-extension-aws version to v2.2.0 (#3149) 2024-12-24 15:59:31 +01:00
396aad9c24 celery: remove deprecated import of ContextManager from typing (#3145)
* celery: remove deprecated import of ContextManager from typing

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* add type checking

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* ruff

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-24 13:55:33 +00:00
375eb6f2cc psycopg: bump versions in test-requirements to support py313 (#3147)
Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-24 13:47:18 +00:00
5fd648eac4 Remove unnecessary configuration of logs exporter in Gen AI samples (#3141)
It is no longer necessary since we now set up the logging pipeline by
default with OTLP exporter.
2024-12-23 19:29:50 +00:00
b03bf0037f asyncpg: bump version in test-requirements (#3146)
Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-23 17:47:09 +00:00
2176e3e43e opentelemetry-instrumentation-falcon: expand supported version to v4 (#3086)
* opentelemetry-instrumentation-falcon: expand supported version to v4

Falcon v4 has a mostly identical interface to v3, and is proved to be fully compatible with `opentelemetry-instrumentation-falcon`. Loose the version check to `<5.0.0` to avoid false `DependencyConflict` alarm.

* opentelemetry-instrumentation-falcon: generate tests for v4

* opentelemetry-instrumentation-falcon: prepare tests for v4

* opentelemetry-instrumentation-falcon: add test preset for `~=3.1.2`

* docs: add changelog for Falcon v4 instrumentation

* opentelemetry-instrumentation-falcon: adjust pylint mark for v4

* _has_fixed_http_target property

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* move changelog to the correct section

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix test and bootstrap_gen

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-23 17:34:48 +00:00
59894979ef [chore] Removed $ from command for contribution guidance (#3114)
The copy in markdown file always copy the $ as well when copying the command,
I need to remove the $ manually each time.

Co-authored-by: Leighton Chen <lechen@microsoft.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-23 14:02:02 +00:00
77708cd7dd grpc: bump grpcio version in test-requirements (#3140)
* grpc: bump grpcio version in test-requirements

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* keep 1.62.0 test

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix toxini

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
2024-12-23 13:36:12 +01:00
73ecf39517 sqlalchemy: bump greenlet version in test requirements and use last requirement file for lint (#3139)
Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-23 10:09:27 +00:00
7eead8f1ae opentelemetry-sdk-extension-aws: make ec2 resource detector silent when loaded outside AWS (#3120)
* opentelemetry-sdk-extension-aws: make ec2 resource detector silent when loaded outside AWS

Assume that if we fail to get the token quickly we are not on AWS.
2024-12-23 09:43:09 +00:00
72576f65e0 Vertex AI instrumentation boilerplate (#3123)
* Vertex AI boilerplate copied from openai-v2

* tox.ini boilerplate

* tox -e generate,generate-workflows
2024-12-21 23:45:53 +00:00
1092344918 Add docstring for instrument_connection() and tests for database drivers (#3108) 2024-12-20 12:24:46 -08:00
54cbf59aae Update package metadata adding "Repository" to project urls (#3119)
Add "Repository" label to project urls pointing to the
opentelemetry-python repo root url.

Having within project urls one entry with the same value for all
packages released by the project will help tools for automatic
dependency management to suggest coherent upgrades for related packages.
2024-12-19 10:15:58 +00:00
1ddba1b518 contributing: add guidance on how to update package versions support (#3090)
* contributing: add guidance for update package versions support

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* update the guide

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* Update CONTRIBUTING.md

* Update CONTRIBUTING.md

Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>

* Update CONTRIBUTING.md

Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>

* Update CONTRIBUTING.md to add docs instructions

* Update CONTRIBUTING.md

* Update CONTRIBUTING.md

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-18 18:05:29 +01:00
52ff7bdd4b feat: Update opentelemetry-instrumentation-confluent-kafka to support confluent-kafka <=2.7.0 (#3100) 2024-12-17 12:33:39 -08:00
6fcaa0a104 Add type hints to Redis (#3110) 2024-12-17 10:40:40 -08:00
cc62d1f05e prepare semconv utilities to support database stability opt-in (#3111) 2024-12-17 09:58:04 -08:00
d155540038 httpx: update type hints to RequestInfo/ResponseInfo (#3105) 2024-12-17 09:43:22 -08:00
f8b0f726ce opentelemetry-instrumentation-openai-v2: updates versions in examples (#3102) 2024-12-17 09:23:08 -08:00
59ecd4d608 infra: improve tox for local development (#2999)
* move pip install from command to deps

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* add docker-test-requirements.txt

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix celery and docs

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* fix tox.ini

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* update docs

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* Update tox.ini

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Leighton Chen <lechen@microsoft.com>
2024-12-17 14:24:50 +01:00
770003dd17 opentelemetry-sdk-extension-aws: make ecs and beanstalk resource detector silent when loaded outside AWS (#3076)
* opentelemetry-sdk-extension-aws: make ecs detector less chatty

Don't print warnings if we are not running inside an ecs instance so we can load the
resource detector more generally and avoid warnings in stderr.

* opentelemetry-sdk-extension-aws: make beanstalk detector less chatty

Don't print warnings if we are not running inside beanstalk so we can load the
resource detector more generally and avoid warnings in stderr.

* Add changelog
2024-12-16 10:28:18 +00:00
38f0e33641 opentelemetry-sdk-extension-aws: make eks detector less chatty (#3074)
* opentelemetry-sdk-extension-aws: make eks detector less chatty

Don't print warnings if we are not running inside an eks instance so we can load the
resource detector more generally and avoid warnings in stderr.

* Update CHANGELOG

---------

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-13 15:39:07 +00:00
37e05aff86 Move starlette's py.typed to the right place (#3103) 2024-12-13 14:53:17 +01:00
490580d6f3 Update version to 1.30.0.dev/0.51b0.dev (#3092) 2024-12-12 11:17:53 +00:00
d2a51b95e5 docs: move AwsLambdaInstrumentor().instrument() to after the lambda function (#3085)
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-11 16:02:37 +01:00
eb03dac1f0 NoOpTracerProvider test case for botocore instrumentation (#3091)
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-11 13:35:50 +00:00
830231092d Update sqlite3 instrumentor doc about explicit cursors (#3088)
* Update sqlite3 instrumentor doc about explicit cursors

* Changelog

---------

Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-11 11:59:21 +00:00
e32aac7b18 Improve SQLite3 example (#3083)
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-11 11:25:01 +00:00
7804e0a4e8 Add type hints to BaseInstrumentor (#3084) 2024-12-11 10:37:51 +01:00
ecf5529f99 opentelemetry-instrumentation-django: bump to 4.2.17 in test requirements (#3077)
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-09 17:08:17 +00:00
c530f0d98f instrumentation: Bump Werkzeug to 3.0.6 (#3078)
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-09 14:46:44 +01:00
eb394c0b21 opentelemetry-instrumentation-tornado: bump tornado in test requirements (#3079) 2024-12-09 14:31:31 +01:00
6134d5a2f9 opentelemetry-instrumentation-openai-v2: coerce openai response_format to semconv format (#3073)
* opentelemetry-instrumentation-openai-v2: coerce openai response_format to semconv format

Signed-off-by: Adrian Cole <adrian.cole@elastic.co>

* changelog

Signed-off-by: Adrian Cole <adrian.cole@elastic.co>

---------

Signed-off-by: Adrian Cole <adrian.cole@elastic.co>
2024-12-09 10:46:13 +01:00
6c92f387aa Fix doc formatting issues (#3062)
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-05 13:53:21 +01:00
f393546d4a Add type hints to SQLite3 (#3057)
* Add type hints to SQLite3

* Apply suggestions from code review

* Update instrumentation/opentelemetry-instrumentation-sqlite3/src/opentelemetry/instrumentation/sqlite3/package.py

* This is a type alias, pylint is dumb

---------

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Aaron Abbott <aaronabbott@google.com>
2024-12-04 14:14:12 +00:00
9cf26836bd CONTRIBUTING: notes abount adding doc for new instrumentation (#3064)
* CONTRIBUTING: notes abount adding doc for new instrumentation

While at it revise the versioning paragraph to take into account the
openai instrumentation.

* Reword doc paragraph

* Update CONTRIBUTING.md

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>

* Add autodoc template

* Add notes about tox

---------

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
2024-12-04 08:27:56 +00:00
76170313f1 Fix instrumentation of SQLAlchemy when using sqlalchemy.engine_from_config (#2816)
* wrap sqlalchemy.engine.create.create_engine

sqlalchemy.engine_from_config directly calls create_engine imported from that path; if we don't
wrap that copy of the `create_engine` call then engines created via engine_from_config are not
instrumented.

* add changelog entry

* Update CHANGELOG.md

Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>

* Update instrumentation/opentelemetry-instrumentation-sqlalchemy/tests/test_sqlalchemy.py

Co-authored-by: Tammy Baylis <96076570+tammy-baylis-swi@users.noreply.github.com>

* make some monkey-patching conditional on the version of SQLAlchemy

* lint

* fix changelog

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>

* Update CHANGELOG.md

---------

Signed-off-by: emdneto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Emídio Neto <9735060+emdneto@users.noreply.github.com>
Co-authored-by: Leighton Chen <lechen@microsoft.com>
Co-authored-by: Shalev Roda <65566801+shalevr@users.noreply.github.com>
Co-authored-by: Tammy Baylis <96076570+tammy-baylis-swi@users.noreply.github.com>
Co-authored-by: Riccardo Magliocchetti <riccardo.magliocchetti@gmail.com>
2024-12-04 10:13:07 +02:00