Esempio n. 1
0
 def __init__(self, name):
     """ Constructor.
     :arg  name, basename used to search for rpm
     """
     AbstractBug.__init__(self)
     self.check_options()
     self.name = name
Esempio n. 2
0
 def __init__(self, name):
     """ Constructor.
     :arg  name, basename used to search for rpm
     """
     AbstractBug.__init__(self)
     self.check_options()
     self.name = name
Esempio n. 3
0
 def __init__(self, url):
     """ Constructor.
     :arg url, complete url to bug
     """
     AbstractBug.__init__(self)
     self.check_options()
     self.bug_url = url
     if not url.startswith('http'):
         self.bug_url = os.path.normpath(self.bug_url)
Esempio n. 4
0
    def __init__(self, bug, user=None, password=None):
        """ Constructor.
        :arg bug, the bug number on bugzilla
        :kwarg user, the username with which to log in in bugzilla.
        :kwarg password, the password associated with this account.
        """
        AbstractBug.__init__(self)
        self.check_options()
        self.bug_num = bug
        bz_url = os.path.join(Settings.current_bz_url, 'xmlrpc.cgi')
        self.bugzilla = Bugzilla(url=bz_url)

        self.log.info("Trying bugzilla cookies for authentication")
        self.user = user
        self.bug = self.bugzilla.getbug(self.bug_num)
        if Settings.login:
             self.login(Settings.user)
        if Settings.assign:
            self.assign_bug()
Esempio n. 5
0
    def __init__(self, bug, user=None, password=None):
        """ Constructor.
        :arg bug, the bug number on bugzilla
        :kwarg user, the username with which to log in in bugzilla.
        :kwarg password, the password associated with this account.
        """
        AbstractBug.__init__(self)
        self.check_options()
        self.bug_num = bug
        bz_url = os.path.join(Settings.current_bz_url, 'xmlrpc.cgi')
        self.bugzilla = Bugzilla(url=bz_url)

        self.log.info("Trying bugzilla cookies for authentication")
        self.user = user
        self.bug = self.bugzilla.getbug(self.bug_num)
        if Settings.login:
            self.login(Settings.user)
        if Settings.assign:
            self.assign_bug()
Esempio n. 6
0
 def check_options(self):
     bad_opts = list(AbstractBug.BZ_OPTIONS)
     bad_opts.extend( ['prebuilt'])
     AbstractBug.do_check_options(self, '--url', bad_opts)
Esempio n. 7
0
 def check_options(self):                     # pylint: disable=R0201
     ''' Raise error if Settings  combination is invalid. '''
     AbstractBug.do_check_options('--url', ['prebuilt', 'other_bz'])
Esempio n. 8
0
 def check_options(self):                    # pylint: disable=R0201
     ''' Raise SettingsError if Settings combinations is invalid. '''
     AbstractBug.do_check_options('--bug', ['prebuilt'])
Esempio n. 9
0
 def check_options(self):
     AbstractBug.do_check_options(self, '--bug', ['prebuilt'])
Esempio n. 10
0
 def check_options(self):  # pylint: disable=R0201
     ''' Raise SettingsError if Settings combinations is invalid. '''
     AbstractBug.do_check_options('--bug', ['prebuilt'])
Esempio n. 11
0
 def check_options(self):
     ''' Raise error if Settings options combination is invalid. '''
     AbstractBug.do_check_options('--name', ['other_bz'])
Esempio n. 12
0
 def check_options(self):
     AbstractBug.do_check_options(self, '--bug', ['prebuilt'])
Esempio n. 13
0
 def check_options(self):  # pylint: disable=R0201
     ''' Raise error if Settings  combination is invalid. '''
     AbstractBug.do_check_options('--url', ['prebuilt', 'other_bz'])
Esempio n. 14
0
 def check_options(self):
     ''' Raise error if Settings options combination is invalid. '''
     AbstractBug.do_check_options('--name', ['other_bz'])
Esempio n. 15
0
 def check_options(self):  # pylint: disable=R0201
     """ Raise error if Settings  combination is invalid. """
     AbstractBug.do_check_options("--url", ["prebuilt", "other_bz"])
Esempio n. 16
0
 def check_options(self):
     bad_opts = list(AbstractBug.BZ_OPTIONS)
     bad_opts.append('cache')
     AbstractBug.do_check_options(self, '--name', bad_opts)