- q_filter = {'_id': account_id}
- update_dict = {'_admin.operations.{}.operationState'.format(op_index): operationState,
- '_admin.operations.{}.detailed-status'.format(op_index): detailed_status,
- '_admin.operations.{}.worker'.format(op_index): None,
- '_admin.current_operation': None}
- self.db.set_one(db_table_name,
- q_filter=q_filter,
- update_dict=update_dict,
- fail_on_empty=False)
+ q_filter = {"_id": account_id}
+ update_dict = {
+ "_admin.operations.{}.operationState".format(op_index): operationState,
+ "_admin.operations.{}.detailed-status".format(op_index): detailed_status,
+ "_admin.operations.{}.worker".format(op_index): None,
+ "_admin.current_operation": None,
+ }
+ self.db.set_one(
+ db_table_name,
+ q_filter=q_filter,
+ update_dict=update_dict,
+ fail_on_empty=False,
+ )