Commit graph

437 commits

Author SHA1 Message Date
442ae98463 Various improvements 2026-07-09 10:12:57 +01:00
b7d95f26ec Add car journey route generator 2026-07-09 10:11:47 +01:00
1e9169b740 Show home marker for car journeys 2026-07-09 10:10:17 +01:00
c6cb06b71e Add car journeys to trips 2026-07-08 09:09:48 +01:00
bc7a2e89d0 Various improvements 2026-06-30 12:31:51 +01:00
5f6cb57c2a Add travel booking and place import scripts 2026-06-24 13:22:51 +01:00
a87c9f993e Improve conference importer and series attendance 2026-06-22 13:08:32 +01:00
dbce9e5358 Improve conference importer date handling 2026-06-22 12:41:33 +01:00
56eea3f7a3 Support nested conference dates in trips 2026-06-22 10:33:56 +01:00
57b2db205d Add conference series pages 2026-06-22 10:25:55 +01:00
098c7e4447 Support inexact conference dates
Closes: #188
2026-06-22 09:25:51 +01:00
fc82cf280a Switch FX rates to Frankfurter 2026-06-20 17:40:12 +01:00
a369c44ae9 Handle FX API usage limit fallback
Closes #211
2026-06-20 17:35:12 +01:00
54e898bc11 Show exploration days before/after each conference on trip page
For each conference, calculate the number of free days available
before and after, relative to the trip boundary or adjacent
conference. Multi-conference trips show the gap between conferences
as "after" the first and "before" the second.

Closes #189

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-23 14:29:29 +01:00
76360c25f3 Refactor add-new-conference into agenda module 2026-03-20 10:36:08 +00:00
feaefba03c Limit weather API calls to cron only, increase cache TTL to 24h
Web view was calling the OpenWeatherMap API directly on every request
(home + all trip locations), causing >1000 calls/day. Now web_view.py
uses cache_only=True everywhere so it never triggers live API calls —
update.py (cron) is the sole API caller. Also warms home location cache
in update_weather(), and increases TTL from 6h to 24h.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 09:27:56 +00:00
04cb3e8179 Add 2-hour TTL cache check to SpaceDevs launch updater
Prevents hitting the SpaceDevs rate limit by skipping the API call
when the launches cache is still fresh (< 2 hours old), matching the
same TTL pattern already used for the active crewed flights cache.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-12 13:28:10 +00:00
f9b79d5a51 Fix trip map unbooked flight pins and timezone-safe busy date comparisons 2026-03-07 12:58:38 +00:00
f38c5327ea Fix YAML validation outside Flask app context 2026-03-06 22:46:40 +00:00
5e2fb72fef trip: use flight_destinations rules for unbooked routes 2026-03-02 13:16:32 +00:00
11ab5f6d28 trip: improve unbooked flight routing and airport pins 2026-03-02 13:09:06 +00:00
9f881d7177 Fix SpaceDevs rate-limiting and cache corruption from throttled responses
Don't write rate-limit/error responses to disk in next_launch_api_data,
so they can't become the "most recent" cache file and cause KeyError crashes
in read_cached_launches. Add defensive results-list checks in
read_cached_launches and get_launches to handle any existing bad files.

Drop refresh=True from the updater's get_active_crewed_flights call so the
2-hour TTL applies; the paginated spacecraft/flight crawl was running on
every hourly cron job and likely causing the burst that triggered throttling.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-21 20:50:05 +00:00
b4f0a5bf5d Add OpenWeatherMap weather forecasts. Closes #48
Show 8-day Bristol home weather on the index and weekends pages.
Show destination weather per day on the trip list and trip page.
Cache forecasts in ~/lib/data/weather/ and refresh via update.py.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-21 20:27:25 +00:00
61e17d9c96 Track dates of English school holidays
Fixes #168
2026-02-21 18:05:19 +00:00
a275683f90 Keep active crewed missions on launches page 2026-02-21 16:00:52 +00:00
49e5a3000e Add attend_start/attend_end fields for partial conference attendance.
Allows recording when you arrive late or leave early at a multi-day
conference. Both fields accept a plain date or datetime with time.
Trip pages display the attendance dates instead of the official
conference dates when these fields are set.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-18 18:14:27 +00:00
53f4252b92 Refactor bus/coach loading and rendering to share code.
Extract `load_road_transport()` as a shared helper for bus and coach,
combining the near-identical route rendering blocks in `get_trip_routes`
and `Trip.elements()` into single `in ("coach", "bus")` branches.
Document transport type patterns in AGENTS.md.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-18 12:52:28 +00:00
c87320415f Show bus stops and coach stations on trip map.
Add case "bus" to get_locations() and bus route handling to
get_trip_routes() in trip.py. Coach stations now populate a dedicated
"coach_station" dict instead of the train station list. Add
"coach_station" (🚌) and "bus_stop" (🚏) emoji types to map.js.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-02-18 12:13:42 +00:00
363967b739 Fix bus stop parsing. 2026-02-18 09:47:08 +00:00
24f4c49429 Fix bus parsing. 2026-02-18 09:46:01 +00:00
960b4a1fc7 Add bus journeys. 2026-02-18 09:39:51 +00:00
828cb40dfa Handle Year Half precision in launch date formatting
Closes: #172

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 11:55:17 +00:00
523dc78b35 Add overall airline, airport, and station stats to trip summary
Aggregate yearly stats into overall totals so the trip stats page
shows flight segments by airline, airports used, and stations used
in the summary section at the top.

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
2026-02-03 09:25:10 +00:00
bc5e595bb0 Add airline, airport, and station stats 2026-01-15 23:05:39 +00:00
f22772d12d Move trip new-country filtering into stats 2026-01-15 22:53:17 +00:00
ddfa77b152 Fix mypy type errors in trip helpers 2026-01-15 22:53:10 +00:00
8a0df48a73 Fix trip stats new-country counting 2026-01-15 22:43:22 +00:00
7e2b79c672 Serve conferences in iCalendar format. 2025-11-14 15:40:05 +00:00
5eab5361b2 Serve events in ics with UTZ timestamps. 2025-11-14 15:14:17 +00:00
77ea6a8afa Generate iCalendar for Thunderbird, etc. 2025-11-14 14:40:19 +00:00
7266568010 Bug fix 2025-11-03 19:39:28 +00:00
8a9126b729 Remove unused code. 2025-11-03 19:31:14 +00:00
e82ca9d9e9 The pandas module has type info. 2025-11-03 19:30:57 +00:00
83e1406ab4 Fix type error. 2025-11-03 19:30:29 +00:00
5d5ce61da4 Hide compliance status on none-Schengen trips. 2025-11-03 12:59:12 +00:00
b4126d04f8 Move two functions to agenda/trip.py 2025-11-03 12:36:13 +00:00
f718535624 Adjust code formatting. 2025-11-03 12:21:59 +00:00
d4b43d70ba Add description field to Conference class. 2025-10-06 10:54:01 +01:00
c6d39ace60 Trip: fix total_distance undercount
Previously Trip.total_distance returned None if any travel leg lacked a
distance, which led to undercounted trip stats (less than flight + train
totals).

Now it accumulates only distances that are present and ignores
missing/falsy values.  The method returns a float and yields 0.0 when no
distances are available.  Docstring updated accordingly.

Fixes #185
2025-08-30 20:46:03 +01:00
ebceb4cb51 Improve space launch email, add tests. 2025-08-12 12:13:27 +01:00