Skip to content

Commit 5e79ca3

Browse files
Merge branch 'master' into table_acls_in_chunks
2 parents 4eee783 + 6b1abd1 commit 5e79ca3

File tree

3 files changed

+8
-2
lines changed

3 files changed

+8
-2
lines changed

dbclient/WorkspaceClient.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -447,7 +447,7 @@ def log_all_workspace_items(self, ws_path, workspace_log_writer, libs_log_writer
447447
num_nbs = 0
448448
if self.is_verbose():
449449
logging.info("Listing: {0}".format(get_args['path']))
450-
if items is not None:
450+
if items:
451451
# list all the users folders only
452452
folders = self.filter_workspace_items(items, 'DIRECTORY')
453453
# should be no notebooks, but lets filter and can check later
@@ -522,7 +522,7 @@ def _recurse_log_all_workspace_items(folder):
522522
if num_nbs_plus:
523523
num_nbs += num_nbs_plus
524524
# log all repos
525-
if repos_log_writer is not None:
525+
if repos_log_writer and repos:
526526
for repo in repos:
527527
repo_path = repo.get('path', "")
528528
if not checkpoint_set.contains(repo_path) and not repo_path.startswith(tuple(exclude_prefixes)):

dbclient/parser.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -461,6 +461,9 @@ def get_pipeline_parser() -> argparse.ArgumentParser:
461461
parser.add_argument('--silent', action='store_true', default=False,
462462
help='Silent all logging of export operations.')
463463

464+
parser.add_argument('--verbose', action='store_true', default=False,
465+
help='Verbose logging')
466+
464467
parser.add_argument('--no-ssl-verification', action='store_true',
465468
help='Set Verify=False when making http requests.')
466469

@@ -550,4 +553,5 @@ def get_pipeline_parser() -> argparse.ArgumentParser:
550553

551554
parser.add_argument('--groups-to-keep', nargs='+', type=str, default=[],
552555
help='List of groups (and therefore users/notebooks) to keep if specified')
556+
553557
return parser

migration_pipeline.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,8 @@ def build_pipeline(args) -> Pipeline:
5555
client_config['base_dir'] = client_config['export_dir']
5656
client_config['export_dir'] = os.path.join(client_config['base_dir'], session) + '/'
5757

58+
client_config['verbose'] = args.verbose
59+
5860
if not args.dry_run:
5961
os.makedirs(client_config['export_dir'], exist_ok=True)
6062

0 commit comments

Comments
 (0)