sitespeedio / sitespeedio/sitespeed.io
Error stopping measurement: Invalid time value
Nobody has claimed this yet.
- Dominant language
- JavaScript
- Stars
- 5k
- Forks
- 624
- Avg merge
- 4h 8m
- Merged PRs (30d)
- 2
Description
Your question
Hello, All
I'm experiencing an issue while calling the measure stop command (short example):
let menuXpath = await this.custom.findElementByXpathSelector("//*[contains(@class, 'settings')]");
await commands.measure.start("Home Page - Open Settings Menu");
await homePage.custom.clickByXpathAndWait(menuXpath);
await commands.measure.stop();
I'm able to find an element, I'm also able to click on the element and see how the page is loading, but the measure.stop() it returns an error:
Error stopping measurement: Invalid time value
I even added hardcoded timeouts to wait after clicking by the XPath selector to be confident that the page was loaded, but I still, see the error.
INFO: Versions OS: win32 10.0.19045 nodejs: v22.9.0 sitespeed.io: 35.0.0 browsertime: 23.0.0 coach: 8.0.2
Could someone please help to resolve this issue?
Thanks in advance!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the measure.start and measure.stop sequence from the report with sitespeed.io 35.0.0, Browsertime 23.0.0, and Node.js 22.9.0, then trace where the “Invalid time value” error is produced. Done means the same interaction stops measurement without the error and the relevant regression is covered by an appropriate test.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- javascript
- Domain
- performance
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 25/100