ensure attractiveness is always an int
Some checks failed
Build and deploy the backend to staging / Build and push image (pull_request) Successful in 2m4s
Build and deploy the backend to staging / Deploy to staging (pull_request) Failing after 18s

This commit is contained in:
2024-09-27 09:47:10 +02:00
parent 097abc5f29
commit cdc9b0ecd1
7 changed files with 89 additions and 168 deletions

View File

@@ -63,7 +63,7 @@ def new_trip(preferences: Preferences, start: tuple[float, float], end: tuple[fl
refined_tour = refiner.refine_optimization(landmarks, base_tour, preferences.max_time_minute, preferences.detour_tolerance_minute)
linked_tour = LinkedLandmarks(refined_tour)
# upon creation of the trip, persistence of both the trip and its landmarks is ensured. Ca
# upon creation of the trip, persistence of both the trip and its landmarks is ensured
trip = Trip.from_linked_landmarks(linked_tour, cache_client)
return trip
@@ -84,4 +84,4 @@ def get_landmark(landmark_uuid: str) -> Landmark:
landmark = cache_client.get(f"landmark_{landmark_uuid}")
return landmark
except KeyError:
raise HTTPException(status_code=404, detail="Landmark not found")
raise HTTPException(status_code=404, detail="Landmark not found")