linting
Some checks failed
Run linting on the backend code / Build (pull_request) Has been cancelled
Run testing on the backend code / Build (pull_request) Has been cancelled
Build and deploy the backend to staging / Deploy to staging (pull_request) Has been cancelled
Build and deploy the backend to staging / Build and push image (pull_request) Has been cancelled

This commit is contained in:
2025-02-19 16:04:18 +01:00
parent 05092e55f1
commit 73f0dc8361
12 changed files with 52 additions and 38 deletions

View File

@@ -94,6 +94,7 @@ def new_trip(preferences: Preferences,
n_tags=0)
start_time = time.time()
# Generate the landmarks from the start location
landmarks, landmarks_short = manager.generate_landmarks_list(
center_coordinates = start,
@@ -103,15 +104,6 @@ def new_trip(preferences: Preferences,
if len(landmarks) == 0 :
raise HTTPException(status_code=500, detail="No landmarks were found.")
###################### store landmarks in json file for debug ######################
landmarks_list = [jsonable_encoder(item) for item in landmarks]
with open('landmarks.json', 'w+') as file:
json.dump(landmarks_list, file, indent=4)
####################################################################################
# insert start and finish to the landmarks list
landmarks_short.insert(0, start_landmark)
landmarks_short.append(end_landmark)