From a860612ab1b528e0038c0b00ea28276af8216c46 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?J=C3=A9r=C3=B4me=20Loyet?= <822436+fatpat@users.noreply.github.com> Date: Thu, 28 Nov 2024 16:43:32 +0100 Subject: [PATCH] dont check --batch/--concurrent/--objects consistency with --list-existing (#348) --- cli/delete.go | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/cli/delete.go b/cli/delete.go index afc5686..ba1cb97 100644 --- a/cli/delete.go +++ b/cli/delete.go @@ -95,8 +95,10 @@ func checkDeleteSyntax(ctx *cli.Context) { if ctx.Int("batch") < 1 { console.Fatal("batch size much be 1 or bigger") } - wantO := ctx.Int("batch") * ctx.Int("concurrent") * 4 - if ctx.Int("objects") < wantO { - console.Fatalf("Too few objects: With current --batch and --concurrent settings, at least %d objects should be used for a valid benchmark. Use --objects=%d", wantO, wantO) + if !ctx.Bool("list-existing") { + wantO := ctx.Int("batch") * ctx.Int("concurrent") * 4 + if ctx.Int("objects") < wantO { + console.Fatalf("Too few objects: With current --batch and --concurrent settings, at least %d objects should be used for a valid benchmark. Use --objects=%d", wantO, wantO) + } } }