mirror of
https://bitbucket.org/chromiumembedded/cef
synced 2025-06-05 21:39:12 +02:00
Use explicit check for python version (see issue #2856)
This commit is contained in:
@ -8,12 +8,11 @@ import datetime
|
||||
import json
|
||||
import os
|
||||
import re
|
||||
import sys
|
||||
|
||||
try:
|
||||
# Python 2
|
||||
if sys.version_info.major == 2:
|
||||
from urllib2 import urlopen
|
||||
except Exception as e:
|
||||
# Python 3
|
||||
else:
|
||||
from urllib.request import urlopen
|
||||
|
||||
# Class used to build the cefbuilds JSON file. See cef_json_builder_example.py
|
||||
|
Reference in New Issue
Block a user