File tree Expand file tree Collapse file tree 4 files changed +15
-1
lines changed Expand file tree Collapse file tree 4 files changed +15
-1
lines changed Original file line number Diff line number Diff line change @@ -110,6 +110,7 @@ class AgnosticClient(AgnosticBaseProperties):
110110 arbiters = ReadOnlyProperty ()
111111 close = DelegateMethod ()
112112 __hash__ = DelegateMethod ()
113+ bulk_write = AsyncRead ()
113114 drop_database = AsyncCommand ().unwrap ("MotorDatabase" )
114115 options = ReadOnlyProperty ()
115116 get_database = DelegateMethod (doc = docstrings .get_database_doc ).wrap (Database )
Original file line number Diff line number Diff line change @@ -53,6 +53,7 @@ from pymongo.read_concern import ReadConcern
5353from pymongo .read_preferences import _ServerMode
5454from pymongo .results import (
5555 BulkWriteResult ,
56+ ClientBulkWriteResult ,
5657 DeleteResult ,
5758 InsertManyResult ,
5859 InsertOneResult ,
@@ -124,6 +125,17 @@ class AgnosticClient(AgnosticBaseProperties[_DocumentType]):
124125 write_concern : Optional [WriteConcern ] = None ,
125126 read_concern : Optional [ReadConcern ] = None ,
126127 ) -> AgnosticDatabase [_DocumentType ]: ...
128+ async def bulk_write (
129+ self ,
130+ models : Sequence [_WriteOp [_DocumentType ]],
131+ session : Optional [ClientSession ] = None ,
132+ ordered : bool = True ,
133+ verbose_results : bool = False ,
134+ bypass_document_validation : Optional [bool ] = None ,
135+ comment : Optional [Any ] = None ,
136+ let : Optional [Mapping ] = None ,
137+ write_concern : Optional [WriteConcern ] = None ,
138+ ) -> ClientBulkWriteResult : ...
127139
128140 HOST : str
129141
Original file line number Diff line number Diff line change 103103from pymongo .srv_resolver import _resolve , _SrvResolver
104104from pymongo .ssl_support import *
105105from pymongo .synchronous .client_session import _TxnState
106+ from pymongo .synchronous .encryption import _Encrypter
106107from pymongo .synchronous .monitor import *
107108from pymongo .synchronous .periodic_executor import *
108109from pymongo .synchronous .periodic_executor import _EXECUTORS
Original file line number Diff line number Diff line change @@ -33,7 +33,7 @@ def attrs(klass):
3333
3434motor_client_only = motor_only .union (["open" ])
3535
36- pymongo_client_only = set (["bulk_write" ]).union (pymongo_only )
36+ pymongo_client_only = set ([]).union (pymongo_only )
3737
3838pymongo_database_only = set ([]).union (pymongo_only )
3939
You can’t perform that action at this time.
0 commit comments