As Transaction::insert(...)'s documentation comment states, the function returns a ConflictError if the ID of the document already exists.
Since this function is buried deep down in BonsaiDB's code, I would suggest adding a hint to that behaviour in the docstring of Collection::push(...), since that is the function users will most likely interact with.
As
Transaction::insert(...)
's documentation comment states, the function returns aConflictError
if the ID of the document already exists.Since this function is buried deep down in
BonsaiDB
's code, I would suggest adding a hint to that behaviour in the docstring ofCollection::push(...)
, since that is the function users will most likely interact with.