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
The samples are assigning filter values using BinaryData.FromString, this usage is incorrect and causes serialisation errors. The code summary for the Value field on OperationalInsightsWorkspacePurgeFilter explains the usage correctly and BinaryData.FromObjectAsJson should be used in these examples.
Expected behavior
Expected behaviour is that the code sample would work when replacing values and updating the filter.
Actual behavior
Actual behaviour is that the code sample errors with a serialisation error due to incorrect usage.
Reproduction Steps
Use the code snippet as is, with the example filter of
Link to sample
https://learn.microsoft.com/en-us/rest/api/loganalytics/workspace-purge/purge?tabs=dotnet
Library name and version
Azure.ResourceManager.OperationalInsights 1.1.0
Language of the Sample
Sample Issue Type
Issue details
The samples are assigning filter values using
BinaryData.FromString
, this usage is incorrect and causes serialisation errors. The code summary for theValue
field onOperationalInsightsWorkspacePurgeFilter
explains the usage correctly andBinaryData.FromObjectAsJson
should be used in these examples.Expected behavior
Expected behaviour is that the code sample would work when replacing values and updating the filter.
Actual behavior
Actual behaviour is that the code sample errors with a serialisation error due to incorrect usage.
Reproduction Steps
Use the code snippet as is, with the example filter of
This will result in the serialisation error
'/' is an invalid start of a value. LineNumber: 0 | BytePositionInLine: 0.
Environment
Windows 11
Visual Studio 2022
dotnet 6
The text was updated successfully, but these errors were encountered: