Google Flights MCP, CLI and Python Library
docs: document multi-city API timeout limitation
Punit Arani4bb146b1c44d
diff --git a/fli/core/builders.py b/fli/core/builders.pyindex 966d21d..2df4591 100644--- a/fli/core/builders.py+++ b/fli/core/builders.py@@ -126,6 +126,11 @@ def build_multi_city_segments(Returns:Tuple of (list of FlightSegment objects, TripType.MULTI_CITY)+ Note:+ Multi-city searches with distinct city pairs may time out due to+ limitations of the Google Flights API endpoint. Round-trip-style+ multi-city (same origin and final destination) works reliably.+"""segments = [FlightSegment(diff --git a/fli/search/flights.py b/fli/search/flights.pyindex a0978d3..fa72009 100644--- a/fli/search/flights.py+++ b/fli/search/flights.py@@ -38,7 +38,7 @@ class SearchFlights:def search(self, filters: FlightSearchFilters, top_n: int = 5- ) -> list[FlightResult | tuple[FlightResult, FlightResult]] | None:+ ) -> list[FlightResult | tuple[FlightResult, ...]] | None:"""Search for flights using the given FlightSearchFilters.Args:@@ -46,11 +46,17 @@ class SearchFlights:top_n: Number of flights to limit the return flight search toReturns:- List of FlightResult objects containing flight details, or None if no results+ List of FlightResult objects (one-way), tuples of FlightResult (round-trip+ or multi-city), or None if no resultsRaises:Exception: If the search fails or returns invalid data+ Note:+ Multi-city searches (TripType.MULTI_CITY) with distinct city pairs may+ time out due to limitations of the Google Flights API endpoint. The+ endpoint reliably supports one-way and round-trip searches.+"""encoded_filters = filters.encode()