Skip to content

Fix 2.7 tests - #2145

Merged
sentrivana merged 41 commits into
masterfrom
ivana/fix-2.7-tests
Jun 7, 2023
Merged

sentrivana merged 41 commits into
masterfrom
ivana/fix-2.7-tests

Conversation

@sentrivana

@sentrivana sentrivana commented May 26, 2023 •

Copy link
Copy Markdown
Collaborator

The Python 2.7 common test suite fails to execute properly, leading the CI to think the tests passed and unfortunately also masking multiple actual test failures.

Fixes #2139

@sentrivana
sentrivana force-pushed the ivana/fix-2.7-tests branch from 0801e6c to cf89324 Compare June 5, 2023 10:04
@sentrivana
sentrivana force-pushed the ivana/fix-2.7-tests branch from cf89324 to c279ef1 Compare June 5, 2023 10:04
@sentrivana sentrivana changed the title Fix UnicodeEncodeError on 2.7 Fix 2.7 tests Jun 5, 2023
@sentrivana

sentrivana commented Jun 6, 2023 •

Copy link
Copy Markdown
Collaborator Author

Hey @Zylphrex, could you please take a look at the failing profiler tests for py 2.7 (here and here)?

TL;DR why this is coming up now: the CI wasn't actually executing the common/gevent test suites for py 2.7 and a handful of the tests were actually failing without us noticing.

I'll take care of the rest but don't know much about the profiler.

@Zylphrex

Zylphrex commented Jun 6, 2023

Copy link
Copy Markdown
Member

Hey @Zylphrex, could you please take a look at the failing profiler tests for py 2.7 (here and here)?

TL;DR why this is coming up now: the CI wasn't actually executing the common/gevent test suites for py 2.7 and a handful of the tests were actually failing without us noticing.

I'll take care of the rest but don't know much about the profiler.

You can disable the profiler tests for 2.7 as it's only meant to work with >3.

@sentrivana

Copy link
Copy Markdown
Collaborator Author

Hey @Zylphrex, could you please take a look at the failing profiler tests for py 2.7 (here and here)?
TL;DR why this is coming up now: the CI wasn't actually executing the common/gevent test suites for py 2.7 and a handful of the tests were actually failing without us noticing.
I'll take care of the rest but don't know much about the profiler.

You can disable the profiler tests for 2.7 as it's only meant to work with >3.

Ok, will do, thanks!

@sentrivana
sentrivana marked this pull request as ready for review June 6, 2023 15:25
Comment thread tests/test_scrubber.py
Comment on lines +108 to +110
assert event["_meta"]["extra"]["auth"] == {"": {"rem": [["!config", "s"]]}}
assert event["_meta"]["breadcrumbs"] == {
"values": {"0": {"data": {"password": {"": {"rem": [["!config", "s"]]}}}}}

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed this because in py2.7 there's an additional 'sys.argv': {'': {'len': 11}}}} in event["_meta"]["extra"], I'm guessing from here. Unsure why this only happens on 2.7 but it doesn't seem to be something that needs to be fixed.

Comment thread tests/test_scrubber.py
assert event["spans"][0]["data"] == {"password": "[Filtered]", "datafoo": "databar"}
assert event["_meta"] == {
"spans": {"0": {"data": {"password": {"": {"rem": [["!config", "s"]]}}}}}
assert event["_meta"]["spans"] == {

Copy link
Copy Markdown
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Same here ^

@sentrivana
sentrivana requested a review from antonpirker June 7, 2023 07:51

@antonpirker antonpirker left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@sentrivana
sentrivana merged commit 55e5e39 into master Jun 7, 2023
@sentrivana
sentrivana deleted the ivana/fix-2.7-tests branch June 7, 2023 07:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

py2.7 common CI tests green even on failure

3 participants