-
Notifications
You must be signed in to change notification settings - Fork 10.3k
Add onroad alert screenshots (part 2) #36353
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
base: master
Are you sure you want to change the base?
Add onroad alert screenshots (part 2) #36353
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 adds automated onroad UI screenshot generation by feeding the UI with real route data and VisionIPC frames, and introduces cases for onroad alerts and states.
- Initialize VisionIPC and publish migrated log events to drive the UI for onroad screenshots
- Add helpers for onroad alert scenarios (small/mid/full, disengaged, override, wide, sidebar, driver cam)
- Cache and reuse a set of camera frames for faster test execution
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
|
||
# Ensure cache directory exists | ||
os.makedirs(DEFAULT_CACHE_DIR, exist_ok=True) | ||
frames_cache = f"{DEFAULT_CACHE_DIR}/test_ui_frames" |
Copilot
AI
Oct 15, 2025
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.
The cache filename is not specific to the route/segment; running tests with different routes or segments risks stale or mismatched frames. Include route name and segment (and optionally camera profile) in the cache key, e.g., DEFAULT_CACHE_DIR/test_ui_frames_{route.fullname}_{segnum}.npz.
frames_cache = f"{DEFAULT_CACHE_DIR}/test_ui_frames" | |
# Make cache filename specific to route and segment | |
safe_route_name = route.fullname.replace("/", "_") | |
frames_cache = f"{DEFAULT_CACHE_DIR}/test_ui_frames_{safe_route_name}_{segnum}.pkl" |
Copilot uses AI. Check for mistakes.
raylib UI Preview |
Includes #36340, but also adds the alert screenshots.