mirror of https://github.com/apache/lucene.git
LUCENE-9412 Do not validate jenkins HTTPS cert
This commit is contained in:
parent
972c84022e
commit
591d844e80
|
@ -18,6 +18,7 @@ import http.client
|
||||||
import os
|
import os
|
||||||
import re
|
import re
|
||||||
import shutil
|
import shutil
|
||||||
|
import ssl
|
||||||
import subprocess
|
import subprocess
|
||||||
import sys
|
import sys
|
||||||
import time
|
import time
|
||||||
|
@ -107,7 +108,9 @@ def fetchAndParseJenkinsLog(url, numRetries):
|
||||||
tests = {}
|
tests = {}
|
||||||
print('[repro] Jenkins log URL: %s\n' % url)
|
print('[repro] Jenkins log URL: %s\n' % url)
|
||||||
try:
|
try:
|
||||||
with urllib.request.urlopen(url) as consoleText:
|
# HTTPS fails at certificate validation, see LUCENE-9412, PEP-476
|
||||||
|
context = ssl._create_unverified_context()
|
||||||
|
with urllib.request.urlopen(url, context=context) as consoleText:
|
||||||
for rawLine in consoleText:
|
for rawLine in consoleText:
|
||||||
line = rawLine.decode(encoding)
|
line = rawLine.decode(encoding)
|
||||||
match = reGitRev.match(line)
|
match = reGitRev.match(line)
|
||||||
|
|
Loading…
Reference in New Issue