From 9a60b4ce9d45aa8e860de5e5519cf031e26e86d7 Mon Sep 17 00:00:00 2001 From: aviau Date: Thu, 16 Nov 2023 13:49:50 -0500 Subject: [PATCH] tasks.py: warn if task_id IS skipped --- opensearchpy/client/tasks.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/opensearchpy/client/tasks.py b/opensearchpy/client/tasks.py index 7e675233..0faebc2e 100644 --- a/opensearchpy/client/tasks.py +++ b/opensearchpy/client/tasks.py @@ -129,7 +129,7 @@ def get( :arg wait_for_completion: Should this request wait until the operation has completed before returning. Default is false. """ - if task_id in SKIP_IN_PATH: + if task_id not in SKIP_IN_PATH: warnings.warn( "Calling client.tasks.get() without a task_id is deprecated " "and will be removed in v8.0. Use client.tasks.list() instead.",