From 75d410641533b2e93ccae0fcd7599176ca441d5f Mon Sep 17 00:00:00 2001 From: Shane Smiskol Date: Wed, 29 May 2024 17:41:33 -0700 Subject: [PATCH] we still can't swap the token live --- selfdrive/ui/qt/maps/map_helpers.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/selfdrive/ui/qt/maps/map_helpers.cc b/selfdrive/ui/qt/maps/map_helpers.cc index 74d3de45cd..16923f7a43 100644 --- a/selfdrive/ui/qt/maps/map_helpers.cc +++ b/selfdrive/ui/qt/maps/map_helpers.cc @@ -12,7 +12,8 @@ #include "selfdrive/ui/qt/api.h" QString get_mapbox_token() { - return MAPBOX_TOKEN.isEmpty() ? CommaApi::create_jwt({}) : MAPBOX_TOKEN; + // Valid for 4 weeks since we can't swap tokens on the fly + return MAPBOX_TOKEN.isEmpty() ? CommaApi::create_jwt({}, 4 * 7 * 24 * 3600) : MAPBOX_TOKEN; } QMapLibre::Settings get_mapbox_settings() {