From fe202a928b4b3c74a6f685846f4e0ca52f5095ea Mon Sep 17 00:00:00 2001 From: Sean Budd Date: Tue, 12 Dec 2023 12:39:47 +1100 Subject: [PATCH] Make add-on store base end point part of the public API (#15893) Relates to #14974 Summary of the issue: Add-on authors wish to have a stable API so that they can change the base URL of the add-on store. This allows add-ons to use a mirror for the add-on store. Description of user facing changes None Description of development approach Change BASE_URL for the add-on store to be public --- source/addonStore/network.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/source/addonStore/network.py b/source/addonStore/network.py index 7fc3907903a..715cd499ec9 100644 --- a/source/addonStore/network.py +++ b/source/addonStore/network.py @@ -40,7 +40,7 @@ from gui.addonStoreGui.viewModels.addonList import AddonListItemVM -_BASE_URL = "https://nvaccess.org/addonStore" +BASE_URL = "https://nvaccess.org/addonStore" _LATEST_API_VER = "latest" """ A string value used in the add-on store to fetch the latest version of all add-ons, @@ -54,11 +54,11 @@ def _getCurrentApiVersionForURL() -> str: def _getAddonStoreURL(channel: Channel, lang: str, nvdaApiVersion: str) -> str: - return f"{_BASE_URL}/{lang}/{channel.value}/{nvdaApiVersion}.json" + return f"{BASE_URL}/{lang}/{channel.value}/{nvdaApiVersion}.json" def _getCacheHashURL() -> str: - return f"{_BASE_URL}/cacheHash.json" + return f"{BASE_URL}/cacheHash.json" class AddonFileDownloader: