diff libervia/frontends/bridge/pb.py @ 4280:4cf98f506269

bridge(constructor): fix template parsing, which was broken following `black` reformating.
author Goffi <goffi@goffi.org>
date Fri, 12 Jul 2024 17:58:06 +0200
parents 0d7bb4df2343
children 3a550e9a2b55
line wrap: on
line diff
--- a/libervia/frontends/bridge/pb.py	Fri Jul 05 17:18:37 2024 +0200
+++ b/libervia/frontends/bridge/pb.py	Fri Jul 12 17:58:06 2024 +0200
@@ -161,9 +161,8 @@
     def register_signal(self, functionName, handler, iface="core"):
         self.signals_handler.register_signal(functionName, handler, iface)
 
-    def action_launch(
-        self, callback_id, data, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+
+    def action_launch(self, callback_id, data, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("action_launch", callback_id, data, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -190,14 +189,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def connect(
-        self,
-        profile_key="@DEFAULT@",
-        password="",
-        options={},
-        callback=None,
-        errback=None,
-    ):
+    def connect(self, profile_key="@DEFAULT@", password='', options={}, callback=None, errback=None):
         d = self.root.callRemote("connect", profile_key, password, options)
         if callback is not None:
             d.addCallback(callback)
@@ -206,9 +198,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def contact_add(
-        self, entity_jid, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def contact_add(self, entity_jid, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("contact_add", entity_jid, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -217,9 +207,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def contact_del(
-        self, entity_jid, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def contact_del(self, entity_jid, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("contact_del", entity_jid, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -237,15 +225,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def contact_update(
-        self,
-        entity_jid,
-        name,
-        groups,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def contact_update(self, entity_jid, name, groups, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("contact_update", entity_jid, name, groups, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -263,9 +243,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def contacts_get_from_group(
-        self, group, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def contacts_get_from_group(self, group, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("contacts_get_from_group", group, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -283,30 +261,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def disco_find_by_features(
-        self,
-        namespaces,
-        identities,
-        bare_jid=False,
-        service=True,
-        roster=True,
-        own_jid=True,
-        local_device=False,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "disco_find_by_features",
-            namespaces,
-            identities,
-            bare_jid,
-            service,
-            roster,
-            own_jid,
-            local_device,
-            profile_key,
-        )
+    def disco_find_by_features(self, namespaces, identities, bare_jid=False, service=True, roster=True, own_jid=True, local_device=False, profile_key="@DEFAULT@", callback=None, errback=None):
+        d = self.root.callRemote("disco_find_by_features", namespaces, identities, bare_jid, service, roster, own_jid, local_device, profile_key)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -314,15 +270,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def disco_infos(
-        self,
-        entity_jid,
-        node="",
-        use_cache=True,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def disco_infos(self, entity_jid, node=u'', use_cache=True, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("disco_infos", entity_jid, node, use_cache, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -331,15 +279,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def disco_items(
-        self,
-        entity_jid,
-        node="",
-        use_cache=True,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def disco_items(self, entity_jid, node=u'', use_cache=True, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("disco_items", entity_jid, node, use_cache, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -375,12 +315,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def encryption_trust_ui_get(
-        self, to_jid, namespace, profile_key, callback=None, errback=None
-    ):
-        d = self.root.callRemote(
-            "encryption_trust_ui_get", to_jid, namespace, profile_key
-        )
+    def encryption_trust_ui_get(self, to_jid, namespace, profile_key, callback=None, errback=None):
+        d = self.root.callRemote("encryption_trust_ui_get", to_jid, namespace, profile_key)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -415,20 +351,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def history_get(
-        self,
-        from_jid,
-        to_jid,
-        limit,
-        between=True,
-        filters="",
-        profile="@NONE@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "history_get", from_jid, to_jid, limit, between, filters, profile
-        )
+    def history_get(self, from_jid, to_jid, limit, between=True, filters='', profile="@NONE@", callback=None, errback=None):
+        d = self.root.callRemote("history_get", from_jid, to_jid, limit, between, filters, profile)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -454,9 +378,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def image_generate_preview(
-        self, image_path, profile_key, callback=None, errback=None
-    ):
+    def image_generate_preview(self, image_path, profile_key, callback=None, errback=None):
         d = self.root.callRemote("image_generate_preview", image_path, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -492,9 +414,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def main_resource_get(
-        self, contact_jid, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def main_resource_get(self, contact_jid, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("main_resource_get", contact_jid, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -512,19 +432,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def menu_launch(
-        self,
-        menu_type,
-        path,
-        data,
-        security_limit,
-        profile_key,
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "menu_launch", menu_type, path, data, security_limit, profile_key
-        )
+    def menu_launch(self, menu_type, path, data, security_limit, profile_key, callback=None, errback=None):
+        d = self.root.callRemote("menu_launch", menu_type, path, data, security_limit, profile_key)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -550,18 +459,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def message_encryption_start(
-        self,
-        to_jid,
-        namespace="",
-        replace=False,
-        profile_key="@NONE@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "message_encryption_start", to_jid, namespace, replace, profile_key
-        )
+    def message_encryption_start(self, to_jid, namespace='', replace=False, profile_key="@NONE@", callback=None, errback=None):
+        d = self.root.callRemote("message_encryption_start", to_jid, namespace, replace, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
         if errback is None:
@@ -578,20 +477,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def message_send(
-        self,
-        to_jid,
-        message,
-        subject={},
-        mess_type="auto",
-        extra={},
-        profile_key="@NONE@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "message_send", to_jid, message, subject, mess_type, extra, profile_key
-        )
+    def message_send(self, to_jid, message, subject={}, mess_type="auto", extra={}, profile_key="@NONE@", callback=None, errback=None):
+        d = self.root.callRemote("message_send", to_jid, message, subject, mess_type, extra, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
         if errback is None:
@@ -608,34 +495,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def notification_add(
-        self,
-        type_,
-        body_plain,
-        body_rich,
-        title,
-        is_global,
-        requires_action,
-        arg_6,
-        priority,
-        expire_at,
-        extra,
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "notification_add",
-            type_,
-            body_plain,
-            body_rich,
-            title,
-            is_global,
-            requires_action,
-            arg_6,
-            priority,
-            expire_at,
-            extra,
-        )
+    def notification_add(self, type_, body_plain, body_rich, title, is_global, requires_action, arg_6, priority, expire_at, extra, callback=None, errback=None):
+        d = self.root.callRemote("notification_add", type_, body_plain, body_rich, title, is_global, requires_action, arg_6, priority, expire_at, extra)
         if callback is not None:
             d.addCallback(lambda __: callback())
         if errback is None:
@@ -643,9 +504,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def notification_delete(
-        self, id_, is_global, profile_key, callback=None, errback=None
-    ):
+    def notification_delete(self, id_, is_global, profile_key, callback=None, errback=None):
         d = self.root.callRemote("notification_delete", id_, is_global, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -654,12 +513,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def notifications_expired_clean(
-        self, limit_timestamp, profile_key, callback=None, errback=None
-    ):
-        d = self.root.callRemote(
-            "notifications_expired_clean", limit_timestamp, profile_key
-        )
+    def notifications_expired_clean(self, limit_timestamp, profile_key, callback=None, errback=None):
+        d = self.root.callRemote("notifications_expired_clean", limit_timestamp, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
         if errback is None:
@@ -676,15 +531,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def param_get_a(
-        self,
-        name,
-        category,
-        attribute="value",
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def param_get_a(self, name, category, attribute="value", profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("param_get_a", name, category, attribute, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -693,19 +540,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def param_get_a_async(
-        self,
-        name,
-        category,
-        attribute="value",
-        security_limit=-1,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "param_get_a_async", name, category, attribute, security_limit, profile_key
-        )
+    def param_get_a_async(self, name, category, attribute="value", security_limit=-1, profile_key="@DEFAULT@", callback=None, errback=None):
+        d = self.root.callRemote("param_get_a_async", name, category, attribute, security_limit, profile_key)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -713,19 +549,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def param_set(
-        self,
-        name,
-        value,
-        category,
-        security_limit=-1,
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "param_set", name, value, category, security_limit, profile_key
-        )
+    def param_set(self, name, value, category, security_limit=-1, profile_key="@DEFAULT@", callback=None, errback=None):
+        d = self.root.callRemote("param_set", name, value, category, security_limit, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
         if errback is None:
@@ -733,15 +558,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def param_ui_get(
-        self,
-        security_limit=-1,
-        app="",
-        extra="",
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def param_ui_get(self, security_limit=-1, app='', extra='', profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("param_ui_get", security_limit, app, extra, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -759,9 +576,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def params_register_app(
-        self, xml, security_limit=-1, app="", callback=None, errback=None
-    ):
+    def params_register_app(self, xml, security_limit=-1, app='', callback=None, errback=None):
         d = self.root.callRemote("params_register_app", xml, security_limit, app)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -788,24 +603,8 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def params_values_from_category_get_async(
-        self,
-        category,
-        security_limit=-1,
-        app="",
-        extra="",
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
-        d = self.root.callRemote(
-            "params_values_from_category_get_async",
-            category,
-            security_limit,
-            app,
-            extra,
-            profile_key,
-        )
+    def params_values_from_category_get_async(self, category, security_limit=-1, app="", extra="", profile_key="@DEFAULT@", callback=None, errback=None):
+        d = self.root.callRemote("params_values_from_category_get_async", category, security_limit, app, extra, profile_key)
         if callback is not None:
             d.addCallback(callback)
         if errback is None:
@@ -813,15 +612,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def presence_set(
-        self,
-        to_jid="",
-        show="",
-        statuses={},
-        profile_key="@DEFAULT@",
-        callback=None,
-        errback=None,
-    ):
+    def presence_set(self, to_jid='', show='', statuses={}, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("presence_set", to_jid, show, statuses, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -857,9 +648,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def private_data_set(
-        self, namespace, key, data, profile_key, callback=None, errback=None
-    ):
+    def private_data_set(self, namespace, key, data, profile_key, callback=None, errback=None):
         d = self.root.callRemote("private_data_set", namespace, key, data, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -868,9 +657,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def profile_create(
-        self, profile, password="", component="", callback=None, errback=None
-    ):
+    def profile_create(self, profile, password='', component='', callback=None, errback=None):
         d = self.root.callRemote("profile_create", profile, password, component)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -888,9 +675,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def profile_is_session_started(
-        self, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def profile_is_session_started(self, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("profile_is_session_started", profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -917,9 +702,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def profile_start_session(
-        self, password="", profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def profile_start_session(self, password='', profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("profile_start_session", password, profile_key)
         if callback is not None:
             d.addCallback(callback)
@@ -928,9 +711,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def profiles_list_get(
-        self, clients=True, components=False, callback=None, errback=None
-    ):
+    def profiles_list_get(self, clients=True, components=False, callback=None, errback=None):
         d = self.root.callRemote("profiles_list_get", clients, components)
         if callback is not None:
             d.addCallback(callback)
@@ -1002,9 +783,7 @@
         else:
             d.addErrback(self._errback, ori_errback=errback)
 
-    def subscription(
-        self, sub_type, entity, profile_key="@DEFAULT@", callback=None, errback=None
-    ):
+    def subscription(self, sub_type, entity, profile_key="@DEFAULT@", callback=None, errback=None):
         d = self.root.callRemote("subscription", sub_type, entity, profile_key)
         if callback is not None:
             d.addCallback(lambda __: callback())
@@ -1023,6 +802,7 @@
             d.addErrback(self._errback, ori_errback=errback)
 
 
+
 class AIOSignalsHandler(SignalsHandler):
 
     def register_signal(self, name, handler, iface="core"):
@@ -1052,6 +832,7 @@
         d = super().bridge_connect(callback=None, errback=None)
         return await d.asFuture(asyncio.get_event_loop())
 
+
     def action_launch(self, callback_id, data, profile_key="@DEFAULT@"):
         d = self.root.callRemote("action_launch", callback_id, data, profile_key)
         d.addErrback(self._errback)
@@ -1067,7 +848,7 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def connect(self, profile_key="@DEFAULT@", password="", options={}):
+    def connect(self, profile_key="@DEFAULT@", password='', options={}):
         d = self.root.callRemote("connect", profile_key, password, options)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1107,37 +888,17 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def disco_find_by_features(
-        self,
-        namespaces,
-        identities,
-        bare_jid=False,
-        service=True,
-        roster=True,
-        own_jid=True,
-        local_device=False,
-        profile_key="@DEFAULT@",
-    ):
-        d = self.root.callRemote(
-            "disco_find_by_features",
-            namespaces,
-            identities,
-            bare_jid,
-            service,
-            roster,
-            own_jid,
-            local_device,
-            profile_key,
-        )
+    def disco_find_by_features(self, namespaces, identities, bare_jid=False, service=True, roster=True, own_jid=True, local_device=False, profile_key="@DEFAULT@"):
+        d = self.root.callRemote("disco_find_by_features", namespaces, identities, bare_jid, service, roster, own_jid, local_device, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def disco_infos(self, entity_jid, node="", use_cache=True, profile_key="@DEFAULT@"):
+    def disco_infos(self, entity_jid, node=u'', use_cache=True, profile_key="@DEFAULT@"):
         d = self.root.callRemote("disco_infos", entity_jid, node, use_cache, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def disco_items(self, entity_jid, node="", use_cache=True, profile_key="@DEFAULT@"):
+    def disco_items(self, entity_jid, node=u'', use_cache=True, profile_key="@DEFAULT@"):
         d = self.root.callRemote("disco_items", entity_jid, node, use_cache, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1158,9 +919,7 @@
         return d.asFuture(asyncio.get_event_loop())
 
     def encryption_trust_ui_get(self, to_jid, namespace, profile_key):
-        d = self.root.callRemote(
-            "encryption_trust_ui_get", to_jid, namespace, profile_key
-        )
+        d = self.root.callRemote("encryption_trust_ui_get", to_jid, namespace, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1179,12 +938,8 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def history_get(
-        self, from_jid, to_jid, limit, between=True, filters="", profile="@NONE@"
-    ):
-        d = self.root.callRemote(
-            "history_get", from_jid, to_jid, limit, between, filters, profile
-        )
+    def history_get(self, from_jid, to_jid, limit, between=True, filters='', profile="@NONE@"):
+        d = self.root.callRemote("history_get", from_jid, to_jid, limit, between, filters, profile)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1229,9 +984,7 @@
         return d.asFuture(asyncio.get_event_loop())
 
     def menu_launch(self, menu_type, path, data, security_limit, profile_key):
-        d = self.root.callRemote(
-            "menu_launch", menu_type, path, data, security_limit, profile_key
-        )
+        d = self.root.callRemote("menu_launch", menu_type, path, data, security_limit, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1245,12 +998,8 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def message_encryption_start(
-        self, to_jid, namespace="", replace=False, profile_key="@NONE@"
-    ):
-        d = self.root.callRemote(
-            "message_encryption_start", to_jid, namespace, replace, profile_key
-        )
+    def message_encryption_start(self, to_jid, namespace='', replace=False, profile_key="@NONE@"):
+        d = self.root.callRemote("message_encryption_start", to_jid, namespace, replace, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1259,18 +1008,8 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def message_send(
-        self,
-        to_jid,
-        message,
-        subject={},
-        mess_type="auto",
-        extra={},
-        profile_key="@NONE@",
-    ):
-        d = self.root.callRemote(
-            "message_send", to_jid, message, subject, mess_type, extra, profile_key
-        )
+    def message_send(self, to_jid, message, subject={}, mess_type="auto", extra={}, profile_key="@NONE@"):
+        d = self.root.callRemote("message_send", to_jid, message, subject, mess_type, extra, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1279,32 +1018,8 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def notification_add(
-        self,
-        type_,
-        body_plain,
-        body_rich,
-        title,
-        is_global,
-        requires_action,
-        arg_6,
-        priority,
-        expire_at,
-        extra,
-    ):
-        d = self.root.callRemote(
-            "notification_add",
-            type_,
-            body_plain,
-            body_rich,
-            title,
-            is_global,
-            requires_action,
-            arg_6,
-            priority,
-            expire_at,
-            extra,
-        )
+    def notification_add(self, type_, body_plain, body_rich, title, is_global, requires_action, arg_6, priority, expire_at, extra):
+        d = self.root.callRemote("notification_add", type_, body_plain, body_rich, title, is_global, requires_action, arg_6, priority, expire_at, extra)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1314,9 +1029,7 @@
         return d.asFuture(asyncio.get_event_loop())
 
     def notifications_expired_clean(self, limit_timestamp, profile_key):
-        d = self.root.callRemote(
-            "notifications_expired_clean", limit_timestamp, profile_key
-        )
+        d = self.root.callRemote("notifications_expired_clean", limit_timestamp, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
@@ -1330,30 +1043,17 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def param_get_a_async(
-        self,
-        name,
-        category,
-        attribute="value",
-        security_limit=-1,
-        profile_key="@DEFAULT@",
-    ):
-        d = self.root.callRemote(
-            "param_get_a_async", name, category, attribute, security_limit, profile_key
-        )
+    def param_get_a_async(self, name, category, attribute="value", security_limit=-1, profile_key="@DEFAULT@"):
+        d = self.root.callRemote("param_get_a_async", name, category, attribute, security_limit, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def param_set(
-        self, name, value, category, security_limit=-1, profile_key="@DEFAULT@"
-    ):
-        d = self.root.callRemote(
-            "param_set", name, value, category, security_limit, profile_key
-        )
+    def param_set(self, name, value, category, security_limit=-1, profile_key="@DEFAULT@"):
+        d = self.root.callRemote("param_set", name, value, category, security_limit, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def param_ui_get(self, security_limit=-1, app="", extra="", profile_key="@DEFAULT@"):
+    def param_ui_get(self, security_limit=-1, app='', extra='', profile_key="@DEFAULT@"):
         d = self.root.callRemote("param_ui_get", security_limit, app, extra, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1363,7 +1063,7 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def params_register_app(self, xml, security_limit=-1, app=""):
+    def params_register_app(self, xml, security_limit=-1, app=''):
         d = self.root.callRemote("params_register_app", xml, security_limit, app)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1378,21 +1078,12 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def params_values_from_category_get_async(
-        self, category, security_limit=-1, app="", extra="", profile_key="@DEFAULT@"
-    ):
-        d = self.root.callRemote(
-            "params_values_from_category_get_async",
-            category,
-            security_limit,
-            app,
-            extra,
-            profile_key,
-        )
+    def params_values_from_category_get_async(self, category, security_limit=-1, app="", extra="", profile_key="@DEFAULT@"):
+        d = self.root.callRemote("params_values_from_category_get_async", category, security_limit, app, extra, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def presence_set(self, to_jid="", show="", statuses={}, profile_key="@DEFAULT@"):
+    def presence_set(self, to_jid='', show='', statuses={}, profile_key="@DEFAULT@"):
         d = self.root.callRemote("presence_set", to_jid, show, statuses, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1417,7 +1108,7 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def profile_create(self, profile, password="", component=""):
+    def profile_create(self, profile, password='', component=''):
         d = self.root.callRemote("profile_create", profile, password, component)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
@@ -1442,7 +1133,7 @@
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())
 
-    def profile_start_session(self, password="", profile_key="@DEFAULT@"):
+    def profile_start_session(self, password='', profile_key="@DEFAULT@"):
         d = self.root.callRemote("profile_start_session", password, profile_key)
         d.addErrback(self._errback)
         return d.asFuture(asyncio.get_event_loop())