Skip to content

Commit ed59d54

Browse files
committed
pandas-devGH-44312 fixes unwanted TypeError when a missing metadata field is missing
1 parent a3bcbf8 commit ed59d54

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

pandas/io/json/_normalize.py

+2
Original file line numberDiff line numberDiff line change
@@ -389,6 +389,8 @@ def _pull_field(
389389
try:
390390
if isinstance(spec, list):
391391
for field in spec:
392+
if result is None:
393+
raise KeyError()
392394
result = result[field]
393395
else:
394396
result = result[spec]

0 commit comments

Comments
 (0)