from ..errors import DpxLdapSessionError
from ..xlate import XLATOR
-__version__ = '1.2.2'
+__version__ = '1.2.3'
LOG = logging.getLogger(__name__)
_ = XLATOR.gettext
self.empty_line()
self.line(color='CYAN')
LOG.info(_('Removing non structural entries from target LDAP instance.'))
+ total = len(self.tgt_dns_current)
+ msg = ngettext('Evaluating one entry.', 'Evaluating {no} entries.', total).format(no=total)
+ LOG.debug(msg)
if not self.quiet:
time.sleep(2)
self.empty_line()
if self.wait_after_write and not self.simulate:
time.sleep(self.wait_after_write)
+ self.empty_line()
if count:
- self.empty_line()
msg = ngettext(
'Removed one not structural entry in target LDAP instance.',
'Removed {no} not structural entries in target LDAP instance.',
self.empty_line()
self.line(color='CYAN')
LOG.info(_('Removing structural entries from target LDAP instance.'))
+ total = len(self.tgt_struct_dns_current)
+ msg = ngettext('Evaluating one entry.', 'Evaluating {no} entries.', total).format(no=total)
+ LOG.debug(msg)
if not self.quiet:
time.sleep(2)
self.empty_line()
if self.wait_after_write and not self.simulate:
time.sleep(self.wait_after_write)
+ self.empty_line()
if count:
- self.empty_line()
msg = ngettext(
'Removed one structural entry in target LDAP instance.',
'Removed {no} structural entries in target LDAP instance.',
self.empty_line()
self.line(color='CYAN')
LOG.info(_('Mirroring structural entries from source to target LDAP instance.'))
+ total = len(self.src_struct_dns)
+ msg = ngettext('Evaluating one entry.', 'Evaluating {no} entries.', total).format(no=total)
+ LOG.debug(msg)
if not self.quiet:
time.sleep(2)
if modified and self.verbose:
if self.verbose == 1:
self.empty_line()
- msg = _('Modifying source data for {!r} ...').format(dn)
- LOG.info(msg)
- LOG.debug('Unmodified data:\n' + pp(unmodified_data))
- LOG.debug('Modified data:\n' + pp(src_attribs.dict()))
+ if self.verbose > 1:
+ msg = _('Modifying source data for {!r} ...').format(dn)
+ LOG.info(msg)
+ LOG.debug('Unmodified data:\n' + pp(unmodified_data))
+ LOG.debug('Modified data:\n' + pp(src_attribs.dict()))
return modified
self.empty_line()
self.line(color='CYAN')
LOG.info(_('Mirroring non-structural entries from source to target LDAP instance.'))
+ total = len(self.src_dns)
+ msg = ngettext('Evaluating one entry.', 'Evaluating {no} entries.', total).format(no=total)
+ LOG.debug(msg)
if not self.quiet:
time.sleep(2)
self.line(color='CYAN')
LOG.info(_('Mirroring members in group entries from source to target LDAP instance.'))
+ total = len(self.src_dns)
+ msg = ngettext('Evaluating one entry.', 'Evaluating {no} entries.', total).format(no=total)
+ LOG.debug(msg)
if not self.quiet:
time.sleep(2)