Closed
Description
Library name and version
Azure.Data.Tables 12.9.1
Describe the bug
Call to table.ClientSubmitTransactionAsync(actions)
throws an InvalidOperationException
when actions
is an empty collection.
There is nothing in the code documentation (tooltip in IDE) which hints that an empty collection is an exceptional case.
This behaviour is unfortunate, because one usually discover this in production logs or during debugging and the exceptions does not add value.
Expected behavior
Passing an empty collection to table.ClientSubmitTransactionAsync(actions)
should be treated as a no-op so we do not have to add defensive code for something non-obvious.
Actual behavior
Call to table.ClientSubmitTransactionAsync(actions)
throws an InvalidOperationException
when actions
is an empty collection.
Reproduction Steps
await tableClient.SubmitTransactionAsync([]);
Environment
No response