Skip to content

Commit 1fdbbef

Browse files
committed
bugzilla: tweak URL detection logging
1 parent 7fd3328 commit 1fdbbef

1 file changed

Lines changed: 5 additions & 8 deletions

File tree

bugzilla/base.py

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -265,27 +265,25 @@ def __init__(self, url=-1, user=None, password=None, cookiefile=-1,
265265

266266
if url:
267267
self.connect(url)
268-
self._init_class_from_url(url)
268+
self._init_class_from_url()
269269
self._init_class_state()
270270

271-
def _init_class_from_url(self, url):
271+
def _init_class_from_url(self):
272272
"""
273273
Detect if we should use RHBugzilla class, and if so, set it
274274
"""
275275
from bugzilla import RHBugzilla
276276

277-
url = self.fix_url(url)
278-
log.debug("Detecting subclass for %s", url)
279-
280277
c = None
281-
if "bugzilla.redhat.com" in url:
278+
if "bugzilla.redhat.com" in self.url:
282279
log.info("Using RHBugzilla for URL containing bugzilla.redhat.com")
283280
c = RHBugzilla
284281
else:
285282
try:
286283
extensions = self._proxy.Bugzilla.extensions()
287284
if "RedHat" in extensions.get('extensions', {}):
288-
log.debug("Found RedHat bugzilla extension")
285+
log.info("Found RedHat bugzilla extension, "
286+
"using RHBugzilla")
289287
c = RHBugzilla
290288
except Fault:
291289
log.debug("Failed to fetch bugzilla extensions", exc_info=True)
@@ -294,7 +292,6 @@ def _init_class_from_url(self, url):
294292
return
295293

296294
self.__class__ = c
297-
log.info("Found subclass %s", c.__name__)
298295

299296
def _init_class_state(self):
300297
"""

0 commit comments

Comments
 (0)