livekit / python-sdks

LiveKit real-time and server SDKs for Python

Home Page:https://docs.livekit.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Room has no field "version" at "WebhookEvent.room"

palma9 opened this issue · comments

When try to receive an event from a weehook it failts trying to get a field "version" that is not present in the response.

I'm calling receive function from WebhookReceiver class.

  File "/usr/local/lib/python3.10/site-packages/livekit/api/webhook.py", line 21, in receive
    return Parse(body, proto_webhook.WebhookEvent())
  File "/usr/local/lib/python3.10/site-packages/google/protobuf/json_format.py", line 421, in Parse
    return ParseDict(js, message, ignore_unknown_fields, descriptor_pool,
  File "/usr/local/lib/python3.10/site-packages/google/protobuf/json_format.py", line 446, in ParseDict
    parser.ConvertMessage(js_dict, message, '')
  File "/usr/local/lib/python3.10/site-packages/google/protobuf/json_format.py", line 487, in ConvertMessage
    self._ConvertFieldValuePair(value, message, path)
  File "/usr/local/lib/python3.10/site-packages/google/protobuf/json_format.py", line 612, in _ConvertFieldValuePair
    raise ParseError(
google.protobuf.json_format.ParseError: Failed to parse room field: Message type "livekit.Room" has no field named "version" at "WebhookEvent.room".
 Available Fields(except extensions): "['sid', 'name', 'emptyTimeout', 'maxParticipants', 'creationTime', 'turnPassword', 'enabledCodecs', 'metadata', 'numParticipants', 'numPublishers', 'activeRecording']".

Seems like something is outdated.

I see the problem.. this is because the Python webhook receiver isn't ignoring unknown fields.. we'll fix this shortly