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
def to_api_repr(self) -> dict:
"""Construct JSON API representation for the parameter.
Returns:
Dict: JSON mapping
"""
value = self.value
converter = _SCALAR_VALUE_TO_JSON_PARAM.get(self.type_)
if converter is not None:
value = converter(value) # type: ignore
resource: Dict[str, Any] = {
"parameterType": {"type": self.type_},
"parameterValue": {"value": value},
}
if self.name is not None:
resource["name"] = self.name
return resource
As you can see, it calls converter with one argument. When using JSON, it uses this converter in _helpers.py:
def _json_from_json(value, field):
"""Coerce 'value' to a pythonic JSON representation, if set or not nullable."""
if _not_null(value, field):
return json.loads(value)
That needs two arguments and it is being given only one resulting in a TypeError: converter() missing 1 required positional argument: 'field'
The text was updated successfully, but these errors were encountered:
Environment details
google-cloud-bigquery
version: 3.14.1Steps to reproduce
The problem is in this code in query.py:
As you can see, it calls converter with one argument. When using JSON, it uses this converter in _helpers.py:
That needs two arguments and it is being given only one resulting in a
TypeError: converter() missing 1 required positional argument: 'field'
The text was updated successfully, but these errors were encountered: