Skip to content

Uncaught TypeError: Cannot read properties of undefined (reading 'startTime') in getCLS logic #6083

Closed
@Tofandel

Description

@Tofandel

Is there an existing issue for this?

How do you use Sentry?

Self-hosted/on-premise

Which package are you using?

@sentry/vue

SDK Version

7.17.2

Framework Version

7.17.2

Link to Sentry event

https://sentry.tukan.hu/share/issue/cc80369f87ff438e88e5d6caf67987c9/

Steps to Reproduce

Move the mouse around on an element creating a layout shift (eg a row that expands on hover)

Expected Result

No error

Actual Result

Js error on line
https://github.com/getsentry/sentry-javascript/blob/master/packages/tracing/src/browser/web-vitals/getCLS.ts#L64
Uncaught TypeError: Cannot read properties of undefined (reading 'startTime')

image

firstSessionEntry and lastSessionEntry are undefined but being used without any check

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions