From 9ef2368c3e92e2ba83bac33754a939e802409cac Mon Sep 17 00:00:00 2001 From: William Hubbs Date: Tue, 8 Mar 2011 14:40:10 -0600 Subject: [PATCH] allow the user to set the cookie file and user agent --- pyzilla.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/pyzilla.py b/pyzilla.py index d1ac168..fc8e8e4 100644 --- a/pyzilla.py +++ b/pyzilla.py @@ -93,9 +93,12 @@ def info(self): return self._parse_response(h.getfile(), sock) class BugZilla(xmlrpclib.Server): - def __init__(self, url, verbose = False): + def __init__(self, url, verbose = False, cookiefile = None, + user_agent=None): xmlrpclib.Server.__init__(self, url, CookieAuthXMLRPCTransport(), - verbose = verbose) + verbose = verbose, + cookiefile = cookiefile, + user_agent = user_agent) def login(self, username, password): self.User.login (dict(login=username,