-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
[Proton] Add warning in Proton viewer about negative byte values #4495
[Proton] Add warning in Proton viewer about negative byte values #4495
Conversation
5ec6eaa
to
2af8559
Compare
2af8559
to
d86ef74
Compare
third_party/proton/proton/viewer.py
Outdated
@@ -187,6 +187,11 @@ def parse(metrics, filename, include, exclude, threshold, depth, format): | |||
# TODO: generalize to support multiple metrics, not just the first one | |||
gf = filter_frames(gf, include, exclude, threshold, metrics[0]) | |||
print(gf.tree(metric_column=metrics, expand_name=True, depth=depth, render_header=False)) | |||
if (f"bytes (inc)" in metrics): |
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.
- It could be just "bytes (inc)" right?
- No
(
and)
. - Can you move the new code into a function? Maybe in the future we could have warnings for other metrics as well
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 didn't get what 2 was but I don't think we should remove the (
and )
around the entire if statement.
third_party/proton/proton/viewer.py
Outdated
|
||
|
||
def emitWarnings(gf, metrics): | ||
if ("bytes (inc)" in metrics): |
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.
Why cannot we make it if "bytes (inc)" in metrics
:?
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.
OK. Updated.
85525cf
to
2336fb6
Compare
No description provided.