Changeset 786 for pykota/trunk

Show
Ignore:
Timestamp:
02/10/03 11:36:33 (22 years ago)
Author:
jalet
Message:

Small problem wrt external requester

Location:
pykota/trunk/pykota
Files:
2 modified

Legend:

Unmodified
Added
Removed
  • pykota/trunk/pykota/config.py

    r785 r786  
    1515# 
    1616# $Log$ 
     17# Revision 1.12  2003/02/10 10:36:33  jalet 
     18# Small problem wrt external requester 
     19# 
    1720# Revision 1.11  2003/02/10 08:50:45  jalet 
    1821# External requester seems to be finally ok now 
     
    145148        """Returns the requester backend to use for a given printer, with its arguments.""" 
    146149        fullrequester = self.config.get(printer, "requester", raw=1) 
    147         (requester, args) = [x.strip() for x in fullrequester.split('(')] 
     150        (requester, args) = [x.strip() for x in fullrequester.split('(', 1)] 
    148151        if args.endswith(')') : 
    149152            args = args[:-1] 
    150153        args = [x.strip() for x in args.split(',')] 
    151154        if not args : 
    152             raise PyKotaConfigError, _("Invalid requester for printer %s") % printer 
     155            raise PyKotaConfigError, _("Invalid requester %s for printer %s") % (fullrequester, printer) 
    153156        return (requester, args) 
    154157         
  • pykota/trunk/pykota/requesters/external.py

    r780 r786  
    1515# 
    1616# $Log$ 
     17# Revision 1.4  2003/02/10 10:36:33  jalet 
     18# Small problem wrt external requester 
     19# 
    1720# Revision 1.3  2003/02/10 00:42:17  jalet 
    1821# External requester should be ok (untested) 
     
    4952        try : 
    5053            pagecounter = int(answer.readline().strip()) 
    51         except IndexError :     
     54        except ValueError :     
    5255            raise PyKotaRequesterError, _("Unable to query printer %s via EXTERNAL(%s)") % (printer, commandline)  
    5356        answer.close()