opentelemetry-instrumentation-aiohttp-client 0.42b0__tar.gz → 0.43b0__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: opentelemetry-instrumentation-aiohttp-client
3
- Version: 0.42b0
3
+ Version: 0.43b0
4
4
  Summary: OpenTelemetry aiohttp client instrumentation
5
5
  Project-URL: Homepage, https://github.com/open-telemetry/opentelemetry-python-contrib/tree/main/instrumentation/opentelemetry-instrumentation-aiohttp-client
6
6
  Author-email: OpenTelemetry Authors <cncf-opentelemetry-contributors@lists.cncf.io>
@@ -18,9 +18,9 @@ Classifier: Programming Language :: Python :: 3.10
18
18
  Classifier: Programming Language :: Python :: 3.11
19
19
  Requires-Python: >=3.7
20
20
  Requires-Dist: opentelemetry-api~=1.12
21
- Requires-Dist: opentelemetry-instrumentation==0.42b0
22
- Requires-Dist: opentelemetry-semantic-conventions==0.42b0
23
- Requires-Dist: opentelemetry-util-http==0.42b0
21
+ Requires-Dist: opentelemetry-instrumentation==0.43b0
22
+ Requires-Dist: opentelemetry-semantic-conventions==0.43b0
23
+ Requires-Dist: opentelemetry-util-http==0.43b0
24
24
  Requires-Dist: wrapt<2.0.0,>=1.0.0
25
25
  Provides-Extra: instruments
26
26
  Requires-Dist: aiohttp~=3.0; extra == 'instruments'
@@ -26,9 +26,9 @@ classifiers = [
26
26
  ]
27
27
  dependencies = [
28
28
  "opentelemetry-api ~= 1.12",
29
- "opentelemetry-instrumentation == 0.42b0",
30
- "opentelemetry-semantic-conventions == 0.42b0",
31
- "opentelemetry-util-http == 0.42b0",
29
+ "opentelemetry-instrumentation == 0.43b0",
30
+ "opentelemetry-semantic-conventions == 0.43b0",
31
+ "opentelemetry-util-http == 0.43b0",
32
32
  "wrapt >= 1.0.0, < 2.0.0",
33
33
  ]
34
34
 
@@ -12,4 +12,4 @@
12
12
  # See the License for the specific language governing permissions and
13
13
  # limitations under the License.
14
14
 
15
- __version__ = "0.42b0"
15
+ __version__ = "0.43b0"
@@ -14,6 +14,7 @@
14
14
 
15
15
  import asyncio
16
16
  import contextlib
17
+ import sys
17
18
  import typing
18
19
  import unittest
19
20
  import urllib.parse
@@ -116,6 +117,11 @@ class TestAioHttpIntegration(TestBase):
116
117
  status_code=status_code,
117
118
  )
118
119
 
120
+ url = f"http://{host}:{port}/test-path?query=param#foobar"
121
+ # if python version is < 3.8, then the url will be
122
+ if sys.version_info[1] < 8:
123
+ url = f"http://{host}:{port}/test-path#foobar"
124
+
119
125
  self.assert_spans(
120
126
  [
121
127
  (
@@ -123,7 +129,7 @@ class TestAioHttpIntegration(TestBase):
123
129
  (span_status, None),
124
130
  {
125
131
  SpanAttributes.HTTP_METHOD: "GET",
126
- SpanAttributes.HTTP_URL: f"http://{host}:{port}/test-path#foobar",
132
+ SpanAttributes.HTTP_URL: url,
127
133
  SpanAttributes.HTTP_STATUS_CODE: int(
128
134
  status_code
129
135
  ),
@@ -136,7 +142,7 @@ class TestAioHttpIntegration(TestBase):
136
142
 
137
143
  def test_schema_url(self):
138
144
  with self.subTest(status_code=200):
139
- host, port = self._http_request(
145
+ self._http_request(
140
146
  trace_config=aiohttp_client.create_trace_config(),
141
147
  url="/test-path?query=param#foobar",
142
148
  status_code=200,
@@ -156,7 +162,7 @@ class TestAioHttpIntegration(TestBase):
156
162
  mock_tracer.start_span.return_value = mock_span
157
163
  with mock.patch("opentelemetry.trace.get_tracer"):
158
164
  # pylint: disable=W0612
159
- host, port = self._http_request(
165
+ self._http_request(
160
166
  trace_config=aiohttp_client.create_trace_config(),
161
167
  url="/test-path?query=param#foobar",
162
168
  )