aboutsummaryrefslogtreecommitdiff
path: root/nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch')
-rw-r--r--nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch13
1 files changed, 4 insertions, 9 deletions
diff --git a/nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch b/nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch
index 16294a4d6cd..511d81c3b01 100644
--- a/nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch
+++ b/nixpkgs/pkgs/development/arduino/platformio/use-local-spdx-license-list.patch
@@ -1,16 +1,11 @@
diff --git a/platformio/package/manifest/schema.py b/platformio/package/manifest/schema.py
-index be49b3ee..d1390a88 100644
+index f293ba5a..a818271f 100644
--- a/platformio/package/manifest/schema.py
+++ b/platformio/package/manifest/schema.py
-@@ -240,9 +240,5 @@ class ManifestSchema(BaseSchema):
+@@ -252,5 +252,4 @@ class ManifestSchema(BaseSchema):
@staticmethod
@memoized(expire="1h")
def load_spdx_licenses():
-- r = requests.get(
-- "https://raw.githubusercontent.com/spdx/license-list-data"
-- "/v3.8/json/licenses.json"
-- )
-- r.raise_for_status()
-- return r.json()
-+ import json
+- spdx_data_url = "https://dl.bintray.com/platformio/dl-misc/spdx-licenses-3.json"
+- return json.loads(fetch_remote_content(spdx_data_url))
+ return json.load(open("@SPDX_LICENSE_LIST_DATA@/json/licenses.json"))