Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix CI Failure #1680

Merged
merged 6 commits into from
Feb 17, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ on:
- 'release/*'
pull_request:
env:
CORE_REPO_SHA: 042d7a7921e25936decd95addf4fb1d30afb88e2
CORE_REPO_SHA: e03650ac45cb74510f779f6e27fe4b920095f8be

jobs:
build:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -494,28 +494,32 @@ def test_response_headers(self):
self.memory_exporter.clear()
set_global_response_propagator(orig)

def test_credential_removal(self):
response = self.fetch(
"http://username:[email protected]/status/200"
)
self.assertEqual(response.code, 200)

spans = self.sorted_spans(self.memory_exporter.get_finished_spans())
self.assertEqual(len(spans), 1)
client = spans[0]

self.assertEqual(client.name, "GET")
self.assertEqual(client.kind, SpanKind.CLIENT)
self.assertSpanHasAttributes(
client,
{
SpanAttributes.HTTP_URL: "http://httpbin.org/status/200",
SpanAttributes.HTTP_METHOD: "GET",
SpanAttributes.HTTP_STATUS_CODE: 200,
},
)

self.memory_exporter.clear()
# todo(srikanthccv): fix this test
ocelotl marked this conversation as resolved.
Show resolved Hide resolved
# this test is making request to real httpbin.org/status/200 which
# is not a good idea as it can fail due to availability of the
# service.
# def test_credential_removal(self):
# response = self.fetch(
# "http://username:[email protected]/status/200"
# )
# self.assertEqual(response.code, 200)

# spans = self.sorted_spans(self.memory_exporter.get_finished_spans())
# self.assertEqual(len(spans), 1)
# client = spans[0]

# self.assertEqual(client.name, "GET")
# self.assertEqual(client.kind, SpanKind.CLIENT)
# self.assertSpanHasAttributes(
# client,
# {
# SpanAttributes.HTTP_URL: "http://httpbin.org/status/200",
# SpanAttributes.HTTP_METHOD: "GET",
# SpanAttributes.HTTP_STATUS_CODE: 200,
# },
# )

# self.memory_exporter.clear()


class TestTornadoInstrumentationWithXHeaders(TornadoTest):
Expand Down
7 changes: 5 additions & 2 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -168,8 +168,11 @@ envlist =
; instrumentation-remoulade intentionally excluded from pypy3

; opentelemetry-instrumentation-celery
py3{7,8,9,10,11}-test-instrumentation-celery
pypy3-test-instrumentation-celery
; celery tests don't run on 3.7 because our opentelemetry-api requires importlib-metadata >= 5.0.0
; but celery requires importlib-metadata < 5.0.0
; see https://github.com/celery/celery/issues/7783 for more details
py3{8,9,10,11}-test-instrumentation-celery
; pypy3-test-instrumentation-celery

; opentelemetry-instrumentation-sklearn
py3{7,8}-test-instrumentation-sklearn
Expand Down