A
adrian
I get those errors when I run:
/usr/local/bin/SquidClamAV_Redirector.py -c
/etc/squid/SquidClamAV_Redirector.conf
##################
Traceback (most recent call last):
File "/usr/local/bin/SquidClamAV_Redirector.py", line 573, in ?
redirector = SquidClamAV_Redirector(config)
File "/usr/local/bin/SquidClamAV_Redirector.py", line 145, in
__init__
self.__start_urlhandler__()
File "/usr/local/bin/SquidClamAV_Redirector.py", line 454, in
__start_urlhandler__
urllib.socket.setdefaulttimeout(self.timeout)
AttributeError: 'module' object has no attribute 'setdefaulttimeout'
#################
the line that is the problem looks like this:
#############
urllib.socket.setdefaulttimeout(self.timeout)
#############
from the global sintax:
##############
def __start_urlhandler__(self):
""" create the urlhandler object """
# set timeout
urllib.socket.setdefaulttimeout(self.timeout)
self.urlhandler = urllib.URLopener()
if self.proxy != {}:
self.urlhandler.proxies = self.proxy
self.urlhandler.addheaders = [('User-agent',
ModuleName + ' ' + str(version))]
##############
can you give me a hint with this matter?
/usr/local/bin/SquidClamAV_Redirector.py -c
/etc/squid/SquidClamAV_Redirector.conf
##################
Traceback (most recent call last):
File "/usr/local/bin/SquidClamAV_Redirector.py", line 573, in ?
redirector = SquidClamAV_Redirector(config)
File "/usr/local/bin/SquidClamAV_Redirector.py", line 145, in
__init__
self.__start_urlhandler__()
File "/usr/local/bin/SquidClamAV_Redirector.py", line 454, in
__start_urlhandler__
urllib.socket.setdefaulttimeout(self.timeout)
AttributeError: 'module' object has no attribute 'setdefaulttimeout'
#################
the line that is the problem looks like this:
#############
urllib.socket.setdefaulttimeout(self.timeout)
#############
from the global sintax:
##############
def __start_urlhandler__(self):
""" create the urlhandler object """
# set timeout
urllib.socket.setdefaulttimeout(self.timeout)
self.urlhandler = urllib.URLopener()
if self.proxy != {}:
self.urlhandler.proxies = self.proxy
self.urlhandler.addheaders = [('User-agent',
ModuleName + ' ' + str(version))]
##############
can you give me a hint with this matter?