from ldap3.core.exceptions import LDAPPasswordIsMandatoryError
+ from ldap3.utils.log import set_library_log_detail_level, ERROR, BASIC, PROTOCOL, NETWORK, EXTENDED
+
# Own modules
-from .global_version import __version__ as __global_version__
-
-from .errors import FunctionNotImplementedError, PpAppError
-
-from .common import pp, terminal_can_colors, to_bytes, to_bool
-
-from .merge import merge_structure
+from .common import pp, to_bool
from .cfg_app import PpCfgAppError, PpConfigApplication
import yaml
# Own modules
-from .global_version import __version__ as __global_version__
+from .common import pp, to_str
-from .errors import FunctionNotImplementedError, PpAppError
+from .homes_admin import PpHomesAdminError, PpHomesAdminApp
-from .common import pp, terminal_can_colors, to_bytes, to_bool, to_str
-
-from .cfg_app import PpCfgAppError, PpConfigApplication
-
-__version__ = '0.5.4'
+__version__ = '0.6.2'
LOG = logging.getLogger(__name__)
- UTC = datetime.timezone.utc
+ ZERO = datetime.timedelta(0)
+
+ # A Utc class.
+
+ class Utc(datetime.tzinfo):
+ """Utc"""
+
+ def utcoffset(self, dt):
+ return ZERO
+
+ def tzname(self, dt):
+ return "UTC"
+
+ def dst(self, dt):
+ return ZERO
+
+ UTC = Utc()
+ # UTC = datetime.timezone.utc
# =============================================================================
LOG.info("Writing status data from {!r} ...".format(self.statusfile))
if self.verbose > 2:
+ # LOG.debug("Status to write:\n{!r}".format(self.status_data))
LOG.debug("Status to write:\n{}".format(pp(self.status_data)))
+ if self.simulate:
+ LOG.info("Simulation mode, status file will not be really written.")
+ return
+
open_args = {}
if six.PY3:
open_args['encoding'] = 'utf-8'