Closed prusfr closed 1 year ago
Thanks for the report.
Yes the doc is a bit misleading. I am currently working on creating a proper documentation for the package. I'll fix this soon.
In the meantime you can still write:
Pipeline().group(
query = {
"field1":"$field1",
"field2":"$field2",
}
)
Fixed in 0.16.2
Pipeline.group() method wont' allow more than 1 field name of class string, whereas doc indicates set or list can be passed. Example :
Pipeline().group(by=["field1", "field2"])
will throw an error. Thus, multi-fields group cannot be set and such a syntax :{$group: {$_id : { field1: "$field1", field2: "$field2"}}}
cannot be achived