-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Fix BrowserWebVitalsPerfData clsTime to cls and make it double type.
#13597
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
Conversation
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.
Pull request overview
This PR fixes the Cumulative Layout Shift (CLS) metric handling in the browser performance monitoring system by renaming clsTime to cls and changing its type from integer to double. CLS is a unitless score (not a time measurement), so the change aligns the field name and type with the metric's actual nature.
- Renamed field from
clsTimetoclsacross the codebase - Changed CLS type from
inttodoubleto properly represent the decimal score - Added conversion logic to scale CLS by 1000 before storing as integer
Reviewed changes
Copilot reviewed 8 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| BrowserWebVitalsPerfDataAnalysisListener.java | Updated to call getCls() and multiply by 1000 before storing as int |
| BrowserWebVitalsPerfDataDecorator.java | Changed getter method from getClsTime() returning int to getCls() returning double |
| BrowserAppWebVitalsPerf.java | Renamed field from clsTime to cls |
| changes.md | Added changelog entry documenting the fix |
| browser-protocol.md | Updated documentation example showing CLS as 0.1 instead of 10 |
| apm-network/src/main/proto | Updated subproject commit reference |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review for a chance to win a $100 gift card. Take the survey.
...r/browser/provider/parser/performance/listener/BrowserWebVitalsPerfDataAnalysisListener.java
Outdated
Show resolved
Hide resolved
|
Agent side code mergrd. We should update e2e for it? |
CHANGESlog.