From 4522a3a9a53ef056d7c52a7cd74d1f4b1276f2e9 Mon Sep 17 00:00:00 2001 From: Jussi Pakkanen Date: Thu, 19 Nov 2015 17:28:39 +0200 Subject: Use plain http connections to wrapdb when ssl is not working (i.e. on OSX). --- wrap.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'wrap.py') diff --git a/wrap.py b/wrap.py index c6c730c..e01dfe8 100644 --- a/wrap.py +++ b/wrap.py @@ -17,7 +17,7 @@ import urllib.request, os, hashlib, shutil import subprocess import sys -from wraptool import build_ssl_context +import wraptool class PackageDefinition: def __init__(self, fname): @@ -94,7 +94,7 @@ class Resolver: def get_data(self, url): blocksize = 10*1024 if url.startswith('https://wrapdb.mesonbuild.com'): - resp = urllib.request.urlopen(url, context=build_ssl_context()) + resp = wraptool.open_wrapdburl(url) else: resp = urllib.request.urlopen(url) dlsize = int(resp.info()['Content-Length']) -- cgit v1.1