mirror of
https://github.com/freedombox/FreedomBox.git
synced 2026-01-21 07:55:00 +00:00
*: pylint: Drop unnecessary 'pass' statements
Signed-off-by: Sunil Mohan Adapa <sunil@medhas.org> Reviewed-by: James Valleroy <jvalleroy@mailbox.org>
This commit is contained in:
parent
22a120d979
commit
eaa3a59791
@ -6,17 +6,14 @@ Project specific errors
|
||||
|
||||
class PlinthError(Exception):
|
||||
"""Base class for all FreedomBox specific errors."""
|
||||
pass
|
||||
|
||||
|
||||
class ActionError(PlinthError):
|
||||
"""Use this error for exceptions when executing an action."""
|
||||
pass
|
||||
|
||||
|
||||
class PackageNotInstalledError(PlinthError):
|
||||
"""Could not complete module setup due to missing package."""
|
||||
pass
|
||||
|
||||
|
||||
class DomainNotRegisteredError(PlinthError):
|
||||
@ -24,7 +21,6 @@ class DomainNotRegisteredError(PlinthError):
|
||||
An action couldn't be performed because this
|
||||
FreedomBox doesn't have a registered domain
|
||||
"""
|
||||
pass
|
||||
|
||||
|
||||
class MissingPackageError(PlinthError):
|
||||
|
||||
@ -229,7 +229,6 @@ def _lockdown_apps(components, lockdown):
|
||||
|
||||
def _is_snapshot_available():
|
||||
"""Return whether it is possible to take filesystem snapshots."""
|
||||
pass
|
||||
|
||||
|
||||
def _take_snapshot():
|
||||
|
||||
@ -131,10 +131,8 @@ def ignore_dbus_error(dbus_error=None, service_error=None):
|
||||
if (dbus_error and parts[1].strip()
|
||||
== 'org.freedesktop.DBus.Error.' + dbus_error):
|
||||
logger.error('Firewalld is not running.')
|
||||
pass
|
||||
elif (service_error and parts[2].strip() == service_error):
|
||||
logger.warning('Ignoring firewall exception: %s', service_error)
|
||||
pass
|
||||
else:
|
||||
raise
|
||||
|
||||
|
||||
@ -33,12 +33,10 @@ CONNECTION_TYPE_NAMES = collections.OrderedDict([
|
||||
|
||||
class ConnectionNotFound(Exception):
|
||||
"""Network connection with a given name could not be found."""
|
||||
pass
|
||||
|
||||
|
||||
class DeviceNotFound(Exception):
|
||||
"""Network device for specified operation could not be found."""
|
||||
pass
|
||||
|
||||
|
||||
def ipv4_string_to_int(address):
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user