1 |
import urllib2, ConfigParser, platform |
import urllib2, ConfigParser, platform |
2 |
|
import socket |
3 |
|
|
4 |
class VersionCheck: |
class VersionCheck: |
5 |
def __init__(self): |
def __init__(self): |
8 |
self.latest = None |
self.latest = None |
9 |
self.info = None |
self.info = None |
10 |
def check(self): |
def check(self): |
11 |
|
socket.setdefaulttimeout(1) |
12 |
auth_handler = urllib2.HTTPBasicAuthHandler() |
auth_handler = urllib2.HTTPBasicAuthHandler() |
13 |
opener = urllib2.build_opener(auth_handler) |
opener = urllib2.build_opener(auth_handler) |
14 |
urllib2.install_opener(opener) |
urllib2.install_opener(opener) |