Skip to content

Commit

Permalink
Merge pull request #999 from vojtechtrefny/3.4-devel_replace-log-exce…
Browse files Browse the repository at this point in the history
…ption-iscsi

iscsi: Replace all log_exception_info calls with log.info
  • Loading branch information
vojtechtrefny committed Dec 6, 2021
2 parents d0b4c2c + 42b5574 commit e5c3773
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions blivet/iscsi.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,6 @@
from . import util
from .flags import flags
from .i18n import _
from .storage_log import log_exception_info
from . import safe_dbus
import os
import re
Expand Down Expand Up @@ -276,8 +275,8 @@ def _get_active_sessions(self):
'org.freedesktop.DBus.ObjectManager',
'GetManagedObjects',
None)[0]
except safe_dbus.DBusCallError:
log_exception_info(log.info, "iscsi: Failed to get active sessions.")
except safe_dbus.DBusCallError as e:
log.info("iscsi: Failed to get active sessions: %s", str(e))
return []

sessions = (obj for obj in objects.keys() if re.match(r'.*/iscsi/session[0-9]+$', obj))
Expand All @@ -301,8 +300,8 @@ def _start_ibft(self):
args = GLib.Variant("(a{sv})", ([], ))
try:
found_nodes, _n_nodes = self._call_initiator_method("DiscoverFirmware", args)
except safe_dbus.DBusCallError:
log_exception_info(log.info, "iscsi: No IBFT info found.")
except safe_dbus.DBusCallError as e:
log.info("iscsi: No IBFT info found: %s", str(e))
# an exception here means there is no ibft firmware, just return
return

Expand Down

0 comments on commit e5c3773

Please sign in to comment.