You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
, an exception is raised when the type of an object is a dict and obj.keys() returns False (e.g. if it's an empty dict).
This is causing my tap to fail even though it should run correctly - in this case, I have a value in my data which can take on a null value (it's defined in the schema as 'integrations': {'type': ['null', 'object']}) and can sometimes be populated, but is sometimes an empty dict ({}).
This causes the somewhat misleading exception to be raised:
KeyError: "property type (object) Expected a dict object.Got: <class 'dict'> {}"
Is the extra check for obj.keys() necessary? By removing it, I can successfully run the tap, since the empty dict doesn't cause any issues.
The text was updated successfully, but these errors were encountered:
Thanks for investigating the code. It helped me to fix things quickly :)
I fixed and released the new version of tap-rest-api (v0.1.3) and tap-bigquery (v0.3.5)
On line 268 of
impl.py
:getschema/getschema/impl.py
Line 268 in f9cd8af
dict
andobj.keys()
returns False (e.g. if it's an empty dict).This is causing my tap to fail even though it should run correctly - in this case, I have a value in my data which can take on a null value (it's defined in the schema as
'integrations': {'type': ['null', 'object']}
) and can sometimes be populated, but is sometimes an empty dict ({}
).This causes the somewhat misleading exception to be raised:
KeyError: "property type (object) Expected a dict object.Got: <class 'dict'> {}"
Is the extra check for
obj.keys()
necessary? By removing it, I can successfully run the tap, since the empty dict doesn't cause any issues.The text was updated successfully, but these errors were encountered: