Skip to content

Commit 574e654

Browse files
committed
Merge branch 'main' into remove-asgi-type
2 parents ea30627 + 8daa8ad commit 574e654

File tree

155 files changed

+3013
-420
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

155 files changed

+3013
-420
lines changed

Diff for: .github/component_owners.yml

+6
Original file line numberDiff line numberDiff line change
@@ -67,3 +67,9 @@ components:
6767

6868
instrumentation/opentelemetry-instrumentation-cassandra:
6969
- mattcontinisio
70+
71+
instrumentation/opentelemetry-instrumentation-asyncio:
72+
- bourbonkk
73+
74+
instrumentation/opentelemetry-instrumentation-psycopg:
75+
- federicobond

Diff for: .github/workflows/instrumentations_0.yml

+31-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
- 'release/*'
77
pull_request:
88
env:
9-
CORE_REPO_SHA: e98af82ff0ebe7e687fda265093aa576cd9ba80f
9+
CORE_REPO_SHA: a1253585f66d63e7c05a19f070f3bfe0ab6460c1
1010

1111
jobs:
1212
instrumentations-0:
@@ -73,6 +73,35 @@ jobs:
7373
- "tornado"
7474
- "tortoiseorm"
7575
os: [ubuntu-20.04]
76+
exclude:
77+
- python-version: py39
78+
package: "sklearn"
79+
- python-version: py310
80+
package: "sklearn"
81+
- python-version: py311
82+
package: "sklearn"
83+
- python-version: pypy3
84+
package: "aiopg"
85+
- python-version: pypy3
86+
package: "asyncpg"
87+
- python-version: pypy3
88+
package: "boto"
89+
- python-version: pypy3
90+
package: "boto3sqs"
91+
- python-version: pypy3
92+
package: "botocore"
93+
- python-version: pypy3
94+
package: "psycopg2"
95+
- python-version: pypy3
96+
package: "remoulade"
97+
- python-version: pypy3
98+
package: "requests"
99+
- python-version: pypy3
100+
package: "sklearn"
101+
- python-version: pypy3
102+
package: "confluent-kafka"
103+
- python-version: pypy3
104+
package: "grpc"
76105
steps:
77106
- name: Checkout Contrib Repo @ SHA - ${{ github.sha }}
78107
uses: actions/checkout@v2
@@ -81,7 +110,7 @@ jobs:
81110
with:
82111
python-version: ${{ env[matrix.python-version] }}
83112
- name: Install tox
84-
run: pip install tox==3.27.1 tox-factor
113+
run: pip install tox
85114
- name: Cache tox environment
86115
# Preserves .tox directory between runs for faster installs
87116
uses: actions/cache@v1

Diff for: .github/workflows/instrumentations_1.yml

+8-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
- 'release/*'
77
pull_request:
88
env:
9-
CORE_REPO_SHA: e98af82ff0ebe7e687fda265093aa576cd9ba80f
9+
CORE_REPO_SHA: a1253585f66d63e7c05a19f070f3bfe0ab6460c1
1010

1111
jobs:
1212
instrumentations-1:
@@ -29,12 +29,18 @@ jobs:
2929
- "wsgi"
3030
- "distro"
3131
- "richconsole"
32+
- "psycopg"
3233
- "prometheus-remote-write"
3334
- "sdkextension-aws"
3435
- "propagator-aws-xray"
3536
- "propagator-ot-trace"
3637
- "resource-detector-container"
3738
os: [ubuntu-20.04]
39+
exclude:
40+
- python-version: py311
41+
package: "prometheus-remote-write"
42+
- python-version: pypy3
43+
package: "prometheus-remote-write"
3844
steps:
3945
- name: Checkout Contrib Repo @ SHA - ${{ github.sha }}
4046
uses: actions/checkout@v2
@@ -43,7 +49,7 @@ jobs:
4349
with:
4450
python-version: ${{ env[matrix.python-version] }}
4551
- name: Install tox
46-
run: pip install tox==3.27.1 tox-factor
52+
run: pip install tox
4753
- name: Cache tox environment
4854
# Preserves .tox directory between runs for faster installs
4955
uses: actions/cache@v1

Diff for: .github/workflows/prepare-patch-release.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ jobs:
5454
with:
5555
python-version: 3.9
5656
- name: Install tox
57-
run: pip install tox==3.27.1
57+
run: pip install tox
5858
- name: run tox
5959
run: tox -e generate
6060

Diff for: .github/workflows/prepare-release-branch.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ jobs:
8181
with:
8282
python-version: 3.9
8383
- name: Install tox
84-
run: pip install tox==3.27.1
84+
run: pip install tox
8585
- name: run tox
8686
run: tox -e generate
8787

@@ -165,7 +165,7 @@ jobs:
165165
with:
166166
python-version: 3.9
167167
- name: Install tox
168-
run: pip install tox==3.27.1
168+
run: pip install tox
169169
- name: run tox
170170
run: tox -e generate
171171

Diff for: .github/workflows/release.yml

+6-6
Original file line numberDiff line numberDiff line change
@@ -45,12 +45,6 @@ jobs:
4545
4646
echo "PRIOR_VERSION_WHEN_PATCH=$prior_version_when_patch" >> $GITHUB_ENV
4747
48-
# check out main branch to verify there won't be problems with merging the change log
49-
# at the end of this workflow
50-
- uses: actions/checkout@v3
51-
with:
52-
ref: main
53-
5448
- run: |
5549
if [[ -z $PRIOR_VERSION_WHEN_PATCH ]]; then
5650
# not making a patch release
@@ -60,6 +54,12 @@ jobs:
6054
fi
6155
fi
6256
57+
# check out main branch to verify there won't be problems with merging the change log
58+
# at the end of this workflow
59+
- uses: actions/checkout@v3
60+
with:
61+
ref: main
62+
6363
# back to the release branch
6464
- uses: actions/checkout@v3
6565

Diff for: .github/workflows/test.yml

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@ on:
66
- 'release/*'
77
pull_request:
88
env:
9-
CORE_REPO_SHA: e98af82ff0ebe7e687fda265093aa576cd9ba80f
9+
CORE_REPO_SHA: a1253585f66d63e7c05a19f070f3bfe0ab6460c1
1010

1111
jobs:
1212
misc:
@@ -24,7 +24,7 @@ jobs:
2424
with:
2525
python-version: "3.10"
2626
- name: Install tox
27-
run: pip install tox==3.27.1
27+
run: pip install tox
2828
- name: Install libsnappy-dev
2929
if: ${{ matrix.tox-environment == 'lint' }}
3030
run: sudo apt-get install -y libsnappy-dev

Diff for: CHANGELOG.md

+32-4
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
77

88
## Unreleased
99

10-
- Drop uspport for 3.7
10+
### Added
11+
12+
- `opentelemetry-instrumentation-psycopg` Initial release for psycopg 3.x
13+
14+
### Fixed
15+
16+
- Remove erroneous `type` attribute from `opentelemetry-instrumentation-asgi`
17+
([#2145](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2145))
18+
19+
## Version 1.23.0/0.44b0 (2024-02-23)
20+
21+
- Drop support for 3.7
1122
([#2151](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2151))
1223
- `opentelemetry-resource-detector-azure` Added 10s timeout to VM Resource Detector
1324
([#2119](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2119))
@@ -17,13 +28,15 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1728
([#2132](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2132))
1829
- `opentelemetry-resource-detector-azure` Changed timeout to 4 seconds due to [timeout bug](https://github.com/open-telemetry/opentelemetry-python/issues/3644)
1930
([#2136](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2136))
20-
- Remove erroneous `type` attribute from `opentelemetry-instrumentation-asgi`
21-
([#2145](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2145))
31+
- `opentelemetry-resource-detector-azure` Suppress instrumentation for `urllib` call
32+
([#2178](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2178))
33+
- AwsLambdaInstrumentor handles and re-raises function exception ([#2245](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2245))
2234

2335
## Version 1.22.0/0.43b0 (2023-12-14)
2436

2537
### Added
26-
38+
- `opentelemetry-instrumentation-asyncio` Add support for asyncio
39+
([#1919](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1943))
2740
- `opentelemetry-instrumentation` Added Otel semantic convention opt-in mechanism
2841
([#1987](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1987))
2942
- `opentelemetry-instrumentation-httpx` Fix mixing async and non async hooks
@@ -1443,3 +1456,18 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
14431456

14441457
- `opentelemetry-ext-wsgi` Initial release
14451458
- `opentelemetry-ext-http-requests` Initial release
1459+
1460+
- Drop support for 3.7
1461+
([#2151](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2151))
1462+
- `opentelemetry-resource-detector-azure` Added 10s timeout to VM Resource Detector
1463+
([#2119](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2119))
1464+
- `opentelemetry-instrumentation-asyncpg` Allow AsyncPGInstrumentor to be instantiated multiple times
1465+
([#1791](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/1791))
1466+
- `opentelemetry-instrumentation-confluent-kafka` Add support for higher versions until 2.3.0 of confluent_kafka
1467+
([#2132](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2132))
1468+
- `opentelemetry-resource-detector-azure` Changed timeout to 4 seconds due to [timeout bug](https://github.com/open-telemetry/opentelemetry-python/issues/3644)
1469+
([#2136](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2136))
1470+
- `opentelemetry-resource-detector-azure` Suppress instrumentation for `urllib` call
1471+
([#2178](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2178))
1472+
- AwsLambdaInstrumentor handles and re-raises function exception ([#2245](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/2245))
1473+

Diff for: CONTRIBUTING.md

+4-4
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ some aspects of development, including testing against multiple Python versions.
3232
To install `tox`, run:
3333

3434
```console
35-
$ pip install tox==3.27.1
35+
$ pip install tox
3636
```
3737

3838
You can run `tox` with the following arguments:
@@ -107,7 +107,7 @@ Run tests:
107107

108108
```sh
109109
# make sure you have all supported versions of Python installed
110-
$ pip install tox==3.27.1 # only first time.
110+
$ pip install tox # only first time.
111111
$ tox # execute in the root of the repository
112112
```
113113

@@ -177,7 +177,7 @@ For a deeper discussion, see: https://github.com/open-telemetry/opentelemetry-sp
177177
## Running Tests Locally
178178

179179
1. Go to your Contrib repo directory. `git clone [email protected]:open-telemetry/opentelemetry-python-contrib.git && cd opentelemetry-python-contrib`.
180-
2. Make sure you have `tox` installed. `pip install tox==3.27.1`.
180+
2. Make sure you have `tox` installed. `pip install tox`.
181181
3. Run `tox` without any arguments to run tests for all the packages. Read more about [tox](https://tox.readthedocs.io/en/latest/).
182182

183183
### Testing against a different Core repo branch/commit
@@ -202,7 +202,7 @@ The continuation integration overrides that environment variable with as per the
202202
Below is a checklist of things to be mindful of when implementing a new instrumentation or working on a specific instrumentation. It is one of our goals as a community to keep the implementation specific details of instrumentations as similar across the board as possible for ease of testing and feature parity. It is also good to abstract as much common functionality as possible.
203203

204204
- Follow semantic conventions
205-
- The instrumentation should follow the semantic conventions defined [here](https://github.com/open-telemetry/opentelemetry-specification/tree/main/semantic_conventions)
205+
- The instrumentation should follow the semantic conventions defined [here](https://github.com/open-telemetry/opentelemetry-specification/tree/main/specification/semantic-conventions.md)
206206
- Extends from [BaseInstrumentor](https://github.com/open-telemetry/opentelemetry-python-contrib/blob/main/opentelemetry-instrumentation/src/opentelemetry/instrumentation/instrumentor.py#L26)
207207
- Supports auto-instrumentation
208208
- Add an entry point (ex. https://github.com/open-telemetry/opentelemetry-python-contrib/blob/f045c43affff6ff1af8fa2f7514a4fdaca97dacf/instrumentation/opentelemetry-instrumentation-requests/pyproject.toml#L44)

Diff for: README.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -128,7 +128,7 @@ Emeritus Maintainers:
128128
1. Go to your Contrib repo directory. `cd ~/git/opentelemetry-python-contrib`.
129129
2. Create a virtual env in your Contrib repo directory. `python3 -m venv my_test_venv`.
130130
3. Activate your virtual env. `source my_test_venv/bin/activate`.
131-
4. Make sure you have `tox` installed. `pip install tox==3.27.1`.
131+
4. Make sure you have `tox` installed. `pip install tox`.
132132
5. Run tests for a package. (e.g. `tox -e test-instrumentation-flask`.)
133133

134134
### Thanks to all the people who already contributed!

Diff for: RELEASING.md

+3-1
Original file line numberDiff line numberDiff line change
@@ -7,8 +7,10 @@
77
* If making a pre-release of stable components (e.g. release candidate),
88
enter the pre-release version number, e.g. `1.9.0rc2`.
99
(otherwise the workflow will pick up the version from `main` and just remove the `.dev` suffix).
10-
* Review and merge the two pull requests that it creates
10+
* Review the two pull requests that it creates.
1111
(one is targeted to the release branch and one is targeted to `main`).
12+
* Merge the one targeted towards the release branch.
13+
* The builds will fail for the `main` pr because of validation rules. Follow the [release workflow](https://github.com/open-telemetry/opentelemetry-python/blob/main/RELEASING.md) for the core repo up until this same point. Change the SHAs of each PR to point at each other to get the `main` builds to pass.
1214

1315
## Preparing a new patch release
1416

Diff for: _template/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
__version__ = "0.44b0.dev"
15+
__version__ = "0.45b0.dev"

Diff for: docs-requirements.txt

+1
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ kafka-python>=2.0,<3.0
3636
mysql-connector-python~=8.0
3737
mysqlclient~=2.1.1
3838
psutil>=5
39+
psycopg~=3.1.17
3940
pika>=0.12.0
4041
pymongo~=3.1
4142
PyMySQL~=0.9.3

Diff for: docs/instrumentation/asyncio/asyncio.rst

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
OpenTelemetry asyncio Instrumentation
2+
==============================================
3+
4+
.. automodule:: opentelemetry.instrumentation.asyncio
5+
:members:
6+
:undoc-members:
7+
:show-inheritance:

Diff for: docs/instrumentation/psycopg/psycopg.rst

+7
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
OpenTelemetry Psycopg Instrumentation
2+
=====================================
3+
4+
.. automodule:: opentelemetry.instrumentation.psycopg
5+
:members:
6+
:undoc-members:
7+
:show-inheritance:

Diff for: docs/instrumentation/psycopg2/psycopg2.rst

+2-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
1-
OpenTelemetry Psycopg Instrumentation
2-
=====================================
1+
OpenTelemetry Psycopg2 Instrumentation
2+
======================================
33

44
.. automodule:: opentelemetry.instrumentation.psycopg2
55
:members:

Diff for: eachdist.ini

+2-2
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ sortfirst=
1616
ext/*
1717

1818
[stable]
19-
version=1.23.0.dev
19+
version=1.24.0.dev
2020

2121
packages=
2222
opentelemetry-sdk
@@ -34,7 +34,7 @@ packages=
3434
opentelemetry-api
3535

3636
[prerelease]
37-
version=0.44b0.dev
37+
version=0.45b0.dev
3838

3939
packages=
4040
all

Diff for: exporter/opentelemetry-exporter-prometheus-remote-write/src/opentelemetry/exporter/prometheus_remote_write/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
__version__ = "0.44b0.dev"
15+
__version__ = "0.45b0.dev"

Diff for: exporter/opentelemetry-exporter-richconsole/pyproject.toml

+1-1
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ classifiers = [
2626
dependencies = [
2727
"opentelemetry-api ~= 1.12",
2828
"opentelemetry-sdk ~= 1.12",
29-
"opentelemetry-semantic-conventions == 0.44b0.dev",
29+
"opentelemetry-semantic-conventions == 0.45b0.dev",
3030
"rich>=10.0.0",
3131
]
3232

Diff for: exporter/opentelemetry-exporter-richconsole/src/opentelemetry/exporter/richconsole/version.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,4 +12,4 @@
1212
# See the License for the specific language governing permissions and
1313
# limitations under the License.
1414

15-
__version__ = "0.44b0.dev"
15+
__version__ = "0.45b0.dev"

Diff for: instrumentation/README.md

+2
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,7 @@
66
| [opentelemetry-instrumentation-aiohttp-server](./opentelemetry-instrumentation-aiohttp-server) | aiohttp ~= 3.0 | No
77
| [opentelemetry-instrumentation-aiopg](./opentelemetry-instrumentation-aiopg) | aiopg >= 0.13.0, < 2.0.0 | No
88
| [opentelemetry-instrumentation-asgi](./opentelemetry-instrumentation-asgi) | asgiref ~= 3.0 | No
9+
| [opentelemetry-instrumentation-asyncio](./opentelemetry-instrumentation-asyncio) | asyncio | No
910
| [opentelemetry-instrumentation-asyncpg](./opentelemetry-instrumentation-asyncpg) | asyncpg >= 0.12.0 | No
1011
| [opentelemetry-instrumentation-aws-lambda](./opentelemetry-instrumentation-aws-lambda) | aws_lambda | No
1112
| [opentelemetry-instrumentation-boto](./opentelemetry-instrumentation-boto) | boto~=2.0 | No
@@ -28,6 +29,7 @@
2829
| [opentelemetry-instrumentation-mysql](./opentelemetry-instrumentation-mysql) | mysql-connector-python ~= 8.0 | No
2930
| [opentelemetry-instrumentation-mysqlclient](./opentelemetry-instrumentation-mysqlclient) | mysqlclient < 3 | No
3031
| [opentelemetry-instrumentation-pika](./opentelemetry-instrumentation-pika) | pika >= 0.12.0 | No
32+
| [opentelemetry-instrumentation-psycopg](./opentelemetry-instrumentation-psycopg) | psycopg >= 3.1.0 | No
3133
| [opentelemetry-instrumentation-psycopg2](./opentelemetry-instrumentation-psycopg2) | psycopg2 >= 2.7.3.1 | No
3234
| [opentelemetry-instrumentation-pymemcache](./opentelemetry-instrumentation-pymemcache) | pymemcache >= 1.3.5, < 5 | No
3335
| [opentelemetry-instrumentation-pymongo](./opentelemetry-instrumentation-pymongo) | pymongo >= 3.1, < 5.0 | No

Diff for: instrumentation/opentelemetry-instrumentation-aio-pika/pyproject.toml

+2-2
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ classifiers = [
2525
]
2626
dependencies = [
2727
"opentelemetry-api ~= 1.5",
28-
"opentelemetry-instrumentation == 0.44b0.dev",
28+
"opentelemetry-instrumentation == 0.45b0.dev",
2929
"wrapt >= 1.0.0, < 2.0.0",
3030
]
3131

@@ -35,7 +35,7 @@ instruments = [
3535
]
3636
test = [
3737
"opentelemetry-instrumentation-aio-pika[instruments]",
38-
"opentelemetry-test-utils == 0.44b0.dev",
38+
"opentelemetry-test-utils == 0.45b0.dev",
3939
"pytest",
4040
"wrapt >= 1.0.0, < 2.0.0",
4141
]

0 commit comments

Comments
 (0)