-
-
Notifications
You must be signed in to change notification settings - Fork 63
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
chore(eap): write script to send scrubbed data into a gcs bucket #6698
Conversation
❌ 1 Tests Failed:
View the top 1 failed tests by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, left a minor comment.
assert params | ||
required_params = [ | ||
"organization_ids", | ||
"start_timestamp", | ||
"end_timestamp", | ||
"table_name", | ||
"limit", | ||
"gcp_bucket_name", | ||
"output_file_path", | ||
] | ||
for param in required_params: | ||
assert param in params |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think you can use Counter()
to compare two unordered lists.
Python 3.11.8 (main, Aug 16 2024, 10:27:21) [Clang 15.0.0 (clang-1500.3.9.4)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> from collections import Counter
>>> l1 = ["one", "two", "three"]
>>> l2 = ["two", "one", "three"]
>>> assert Counter(l1) == Counter(l2), "Lists must be same!"
>>> l1.append("four")
>>> assert Counter(l1) == Counter(l2), "Lists must be same!"
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
AssertionError: Lists must be same!
Also, consider adding a message along with assert
to make debugging easier.
Closes https://github.com/getsentry/eap-planning/issues/139