Skip to content

Commit 5d51c98

Browse files
committed
add debugging prints
Signed-off-by: Yee Hing Tong <wild-endeavor@users.noreply.github.com>
1 parent 6a4c2d8 commit 5d51c98

File tree

1 file changed

+14
-0
lines changed

1 file changed

+14
-0
lines changed

flytekit/core/context_manager.py

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -414,6 +414,20 @@ def get(
414414
if os.path.exists(fpath):
415415
with open(fpath, encode_mode) as f:
416416
return f.read().strip()
417+
418+
print(
419+
f"Unable to get in SecretsManager - inputs: {group=} {key=}, {group_version=}, {encode_mode=}", flush=True
420+
)
421+
print("Environment variables:", flush=True)
422+
for ev_k, ev_v in os.environ.items():
423+
print(f"{ev_k}: {ev_v[:7]}", flush=True)
424+
print("<<== End environment variables ==>>", flush=True)
425+
426+
import traceback
427+
428+
traceback.print_stack()
429+
print("<<== End stack trace ==>>", flush=True)
430+
417431
raise ValueError(
418432
f"Please make sure to add secret_requests=[Secret(group={group}, key={key})] in @task. Unable to find secret for key {key} in group {group} "
419433
f"in Env Var:{env_var} and FilePath: {fpath}"

0 commit comments

Comments
 (0)