Skip to content

Commit 5497ab2

Browse files
committed
correction, let's keep source in ctx
1 parent 590525f commit 5497ab2

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

pydantic_settings/main.py

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -428,6 +428,9 @@ def _settings_build_values(
428428
if line.get("type", "") == "missing":
429429
continue
430430
line['loc'] = [source_name] + line['loc']
431+
ctx = line.get("ctx", {})
432+
ctx["source"] = source_name
433+
line['ctx'] = ctx
431434
details = InitErrorDetails(**line)
432435
all_line_errors.append(details)
433436

0 commit comments

Comments
 (0)