Skip to content

fix: Timezone display, region pack naming, eBird filtering, and service restart#28

Merged
mverteuil merged 5 commits intomainfrom
fix/timezone-and-region-pack-fixes
Feb 22, 2026
Merged

fix: Timezone display, region pack naming, eBird filtering, and service restart#28
mverteuil merged 5 commits intomainfrom
fix/timezone-and-region-pack-fixes

Conversation

@mverteuil
Copy link
Owner

Summary

  • Timezone display: Convert timestamps to user's configured timezone for display in dashboard and API responses
  • Region pack naming: Use release_name (e.g., na-east-054-2026.02.db) instead of region_id for file naming
  • eBird filtering: Treat unknown species as "absent" to block species not in regional database
  • Service restart: Use detached process for supervisord restart so FastAPI can restart itself from UI
  • API timestamps: Add Z suffix to datetime responses to indicate UTC for JavaScript clients

Test plan

  • Verify dashboard shows times in local timezone (America/Toronto)
  • Verify eBird filtering blocks African/European species at Toronto location
  • Verify Ontario species are detected correctly
  • Verify FastAPI restart works from UI
  • All pre-commit checks pass
  • Presentation manager tests pass (30/30)

…ce restart

- Convert timestamps to user's configured timezone for display in dashboard
  and API responses (presentation.py, models.py, detections_api_routes.py)
- Use release_name instead of region_id for region pack file naming
  (region_pack_service.py, region_pack_status.py, update_daemon.py, update.py)
- Treat unknown species as "absent" in eBird filtering to block species
  not in regional database (detections_api_routes.py)
- Use detached process for supervisord restart so FastAPI can restart itself
  (service_strategies.py)
- Add Z suffix to API datetime responses to indicate UTC (detections.py)
- Update tests for region pack naming changes
The restart_service method now uses subprocess.Popen with start_new_session
to allow the FastAPI service to restart itself from the UI.
…p behavior

The Z suffix serializer should only apply to JSON output, not model_dump().
Also fixes +00:00Z invalid format by replacing +00:00 with Z.
When species is not found in regional database, check the
unknown_species_behavior config setting instead of always blocking.
@mverteuil mverteuil merged commit 87ae2b0 into main Feb 22, 2026
3 checks passed
@mverteuil mverteuil deleted the fix/timezone-and-region-pack-fixes branch February 22, 2026 22:25
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.

1 participant