-
-
Notifications
You must be signed in to change notification settings - Fork 4.2k
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(view-hierarchy): Add proguard file size to span #44826
chore(view-hierarchy): Add proguard file size to span #44826
Conversation
Tracking the file size so we can understand its impact on timing
src/sentry/lang/java/utils.py
Outdated
dif_paths = ProjectDebugFile.difcache.fetch_difs(project, [uuid], features=["mapping"]) | ||
debug_file_path = dif_paths.get(uuid) | ||
if debug_file_path is None: | ||
return | ||
|
||
proguard_file_size_in_mb = os.path.getsize(debug_file_path) / (1024 * 1024.0) |
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.
Should we wrap this in a try catch just in case, even if we're confident it wont fail? I think os.path.getsize
might throw an error if it cant reach the file for whatever reason
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.
oh good point, I'll do that. Thanks for the suggestion
Tracking the file size so we can understand its impact on timing
Tracking the file size so we can understand its impact on timing
Tracking the file size so we can understand its impact on timing