Skip to content

Support null speed values from Geolocation API#81

Draft
google-labs-jules[bot] wants to merge 1 commit into
devfrom
jules/null-speed-support-1459445917778657294
Draft

Support null speed values from Geolocation API#81
google-labs-jules[bot] wants to merge 1 commit into
devfrom
jules/null-speed-support-1459445917778657294

Conversation

@google-labs-jules
Copy link
Copy Markdown
Contributor

This change enables the speedometer to react to null speed values from the Geolocation API (which can indicate valid but calculable state, e.g. momentary loss of precision) by showing the placeholder (———) instead of sticking to the last known non-null speed. This prevents misleading "frozen" speed readings when the GPS is active but temporarily unable to determine speed. A new Playwright E2E test was added to verify this behavior by simulating a transition from a valid speed to a null speed.


PR created automatically by Jules for task 1459445917778657294 started by @samuel-skean

Treats explicit `null` speed updates from Geolocation API as valid updates, transitioning the UI to the placeholder state instead of preserving the last known speed. This ensures that when the device reports it cannot calculate speed (but is active), the UI reflects this state accurately.

- Modified `src/app.ts` to accept `speed: null` in `handlePosition`.
- Added E2E regression test `tests/e2e/null_speed.spec.ts` mocking geolocation updates.
@google-labs-jules
Copy link
Copy Markdown
Contributor Author

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@cloudflare-workers-and-pages
Copy link
Copy Markdown

cloudflare-workers-and-pages Bot commented Jan 11, 2026

Deploying speedometer with  Cloudflare Pages  Cloudflare Pages

Latest commit: 7b1e4ab
Status: ✅  Deploy successful!
Preview URL: https://31b19ac5.speedometer-f1o.pages.dev
Branch Preview URL: https://jules-null-speed-support-145.speedometer-f1o.pages.dev

View logs

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

0 participants