In addition to the configured FOLLOW_LAUNCHES, also send emails for any
launch whose mission.type == "Test Flight" even if its slug is not in
FOLLOW_LAUNCHES.
Fixes#192.
The accommodation page has been updated to provide a more comprehensive and dynamic view of travel statistics.
Previously, the page only displayed hard-coded statistics for total nights away and abroad for the year 2024. This required manual updates each year and didn't provide historical context.
This commit introduces the following changes:
* **Dynamically Calculate Yearly Stats:** The `accommodation_list` view in `web_view.py` now calculates statistics for every year found in the accommodation data. It correctly handles stays that span across multiple years.
* **Display All Years:** The `accommodation.html` template now iterates through a list of all calculated yearly stats, displaying a summary for each year automatically.
* **Add Percentage of Year:** The template also calculates and displays what percentage of the year the "total nights" and "nights abroad" represent. This includes logic to correctly account for leap years (366 days) for an accurate calculation.
These changes make the statistics more informative and ensure the page remains relevant over time without needing further manual code adjustments.
- Move all parsing logic from parse_airbnb.py to agenda/airbnb.py
- Update parse_airbnb.py to use the new library module
- Add comprehensive tests in tests/test_airbnb.py covering all functions
- Maintain backward compatibility for the command-line interface
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Replace hardcoded 2025 data with astronomically calculated dates
- Use solar longitude to determine precise meteor shower peak dates
- Calculate real-time moon phases for accurate viewing conditions
- Support for any year with automatic date calculations
- Include parent body information and meteor velocities
- Remove caching layer for real-time calculations
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Implements birthday reminder emails that are sent daily at 9 AM for birthdays
occurring within the next 7 days. Integrates with existing birthday.py module
and mail system to send notifications with appropriate timing-based subjects.
Fixes#171🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Simplify the location tracking function by extracting travel data directly
from trip objects instead of requiring separate YAML file parameters.
Changes:
- Remove airport, train, and ferry location helper functions that required
separate YAML data lookups
- Update get_location_for_date signature to only take target_date and trips
- Extract flight/train/ferry details directly from trip.travel items
- Use embedded airport/station/terminal objects from trip data
- Remove YAML file parsing from weekends function
- Update test calls to use new simplified signature
This eliminates duplicate data loading and simplifies the API while
maintaining all existing functionality.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Add /trip/<start>/debug endpoint that displays the complete trip object
data in pretty-printed JSON format with syntax highlighting. Includes
both raw data and computed properties for debugging purposes.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Remove complex country-based return home assumptions since we now track actual train and ferry travel back to the UK. The system can rely on real travel data rather than heuristics.
- Remove NEARBY_BALKAN_COUNTRIES constant
- Remove geographic assumptions about returning home after trips
- Keep only UK trip ending logic (if trip ends in UK, you're home)
With complete train/ferry tracking, actual return travel is captured rather than inferred.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add helper functions for train and ferry location extraction
- Update get_location_for_date to consider trains and ferries alongside flights
- Parse stations.yaml and ferry_terminals.yaml for location data
- Handle UK vs international locations consistently for all transport modes
- Add comprehensive tests for new train and ferry location helpers
- Format code with black for consistent style
Now tracks complete travel history including flights, trains, ferries, and accommodation for accurate location determination.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
- Add pytest fixtures for shared data to avoid reparsing YAML files
- Split large test into specific test functions for better modularity
- Add comprehensive test coverage for busy_event, location tracking, and helper functions
- Improve test performance with session-scoped fixtures
- Enable individual test execution with pytest -k
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Expand return-home heuristic to cover more countries and reorganize logic
to prioritize trip-based location detection over individual travel data.
Key changes:
1. Add Balkan countries (GR, AL, XK, HR, etc.) to European heuristic
2. Add major international countries (US, CA, IN, JP, etc.) to heuristic
3. Change condition from >1 day to >=1 day for faster return detection
4. Move trip heuristic check before individual flight/accommodation lookup
This fixes cases where stopovers or connections (like Kosovo→Albania on
July 1) were overriding the trip-based "return home" logic. Now correctly
detects return home from all types of trips including Balkan and
international destinations.
All weekend location tests now pass - ensures locations show "Bristol"
when free (no events) or show trip locations when traveling.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
Adjust European short trip heuristic from >3 days to >1 day to correctly
detect when user has returned home from European trips. This fixes the
April 29-30, 2023 case where the location incorrectly showed "Sankt Georg, Hamburg"
instead of "Bristol" when the user was free (no events scheduled) after
the foss-north trip ended on April 27.
The previous logic required more than 3 days to pass before assuming
return home from European countries, but for short European trips by
rail/ferry, users typically return within 1-2 days.
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>
When traveling to nearby European countries by rail or ferry,
return journeys often aren't recorded in flight/accommodation
data. Added logic to assume you've returned home after short
European trips that ended >3 days ago.
Covers common rail/ferry destinations: Belgium, Netherlands,
France, Germany, Switzerland, Austria, Italy, Spain.
Example: Feb 2-5 trip to Brussels (by rail), Feb 18 now
correctly shows "Bristol" instead of "Brussels".
🤖 Generated with [Claude Code](https://claude.ai/code)
Co-Authored-By: Claude <noreply@anthropic.com>