'Called when a directory scan is about to start
@param description {unicode} A string suitable for showing the user
about the upcoming operation
@param dirs {set of unicode} The directories about to be scanned'

def onScanStarted(self, description, dirs=set()):

    self.debug('scan    started:    %s    (%s    dirs)', description, len(dirs))
    assert dirs, 'onScanStarted    expects    non-empty    directories'
    if (not dirs):
        return
    for dir_path in dirs:
        self._dirs[dir_path] += 1
    self.send(type='scan-progress', message=description, completed=len(self._completed_dirs), total=len(self._dirs))
