Skip to content

[Eventgrid] Fix sample cs2_publish_custom_events_to_a_domain_topic #16042

@rakshith91

Description

@rakshith91

Here's the trace

$ c:/Users/Administrator/Documents/Workspace/azure-sdk-for-python/envegrid/Scri
pts/python.exe c:/Users/Administrator/Documents/Workspace/azure-sdk-for-python/
sdk/eventgrid/azure-eventgrid/samples/champion_scenarios/cs2_publish_custom_eve
nts_to_a_domain_topic.py
Traceback (most recent call last):
  File "c:/Users/Administrator/Documents/Workspace/azure-sdk-for-python/sdk/eventgrid/azure-eventgrid/samples/champion_scenarios/cs2_publish_custom_events_to_a_domain_topic.py", line 44, in <module>
    data_version="2.0"
  File "C:\Users\Administrator\Documents\Workspace\azure-sdk-for-python\envegrid\lib\site-packages\azure\core\tracing\decorator.py", line 83, in wrapper_use_tracer
    return func(*args, **kwargs)
  File "c:\users\administrator\documents\workspace\azure-sdk-for-python\sdk\eventgrid\azure-eventgrid\azure\eventgrid\_publisher_client.py", line 132, in send
    self._client.publish_events(self._topic_hostname, cast(List[InternalEventGridEvent], events), **kwargs)
  File "c:\users\administrator\documents\workspace\azure-sdk-for-python\sdk\eventgrid\azure-eventgrid\azure\eventgrid\_generated\operations\_event_grid_publisher_client_operations.py", line 75, in publish_events
    raise HttpResponseError(response=response)
azure.core.exceptions.HttpResponseError: (BadRequest) Unexpected token when reading JSON. Expected: StartObject, actual: StartArray. Report '00b1077e-af42-4382-8faf-7fcf9f0dee44:4:1/8/2021 5:49:50 PM (UTC)' to our forums for assistance or raise a support ticket

Inestigate and fix the sample

Metadata

Metadata

Assignees

Labels

ClientThis issue points to a problem in the data-plane of the library.Event GridMessagingMessaging crewblocking-releaseBlocks release

Type

No type

Projects

No projects

Relationships

None yet

Development

No branches or pull requests

Issue actions