slidge 0.2.1__tar.gz → 0.2.2__tar.gz
Sign up to get free protection for your applications and to get access to all the features.
- {slidge-0.2.1 → slidge-0.2.2}/PKG-INFO +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/pyproject.toml +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/__version__.py +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/base.py +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/chat_command.py +5 -2
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/register.py +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/user.py +1 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/gateway.py +3 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/attachment.py +12 -1
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/models.py +4 -0
- {slidge-0.2.1 → slidge-0.2.2}/LICENSE +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/README.md +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/__main__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/adhoc.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/admin.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/command/categories.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/contact/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/contact/contact.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/contact/roster.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/config.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/caps.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/disco.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/message/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/message/chat_state.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/message/marker.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/message/message.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/admin.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/mam.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/misc.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/owner.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/muc/ping.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/presence.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/registration.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/search.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/session_dispatcher.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/util.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/dispatcher/vcard.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/avatar.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/base.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/db.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/disco.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/lock.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/message.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/message_maker.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/message_text.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/presence.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/mixins/recipient.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/pubsub.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/core/session.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/env.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/old_user_store.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/script.py.mako +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/09f27f098baa_add_missing_attributes_in_room.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/15b0bd83407a_remove_bogus_unique_constraints_on_room_.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/2461390c0af2_store_contacts_caps_verstring_in_db.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/29f5280c61aa_store_subject_setter_in_room.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/2b1f45ab7379_store_room_subject_setter_by_nickname.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/3071e0fa69d4_add_contact_client_type.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/45c24cc73c91_add_bob.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/5bd48bfdffa2_lift_room_legacy_id_constraint.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/82a4af84b679_add_muc_history_filled.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/8b993243a536_add_vcard_content_to_contact_table.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/8d2ced764698_rely_on_db_to_store_contacts_rooms_and_.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/aa9d82a7f6ef_db_creation.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/abba1ae0edb3_store_avatar_legacy_id_in_the_contact_.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/b33993e87db3_move_everything_to_persistent_db.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/b64b1a793483_add_source_and_legacy_id_for_archived_.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/c4a8ec35a0e8_per_room_user_nick.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/e91195719c2c_store_users_avatars_persistently.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/avatar.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/meta.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/db/store.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/group/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/group/archive.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/group/bookmarks.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/group/participant.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/group/room.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/main.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/migration.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/py.typed +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/delivery_receipt.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/link_preview/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/link_preview/link_preview.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/link_preview/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/roster.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0077/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0077/register.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0077/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0100/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0100/gateway.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0100/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0153/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0153/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0153/vcard_avatar.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0264/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0264/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0264/thumbnail.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0292/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0292/vcard4.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0313/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0313/mam.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0313/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0317/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0317/hats.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0317/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0356_old/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0356_old/privilege.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0356_old/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0424/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0424/retraction.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0424/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0490/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0490/mds.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/slixfix/xep_0490/stanza.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/__init__.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/archive_msg.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/conf.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/db.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/test.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/types.py +0 -0
- {slidge-0.2.1 → slidge-0.2.2}/slidge/util/util.py +0 -0
@@ -175,7 +175,9 @@ class ChatCommandProvider:
|
|
175
175
|
else:
|
176
176
|
if f.type == "list-multi":
|
177
177
|
msg.reply(
|
178
|
-
"Multiple selection allowed, use
|
178
|
+
"Multiple selection allowed, use new lines as a separator, ie, "
|
179
|
+
"one selected item per line. To select no item, reply with a space "
|
180
|
+
"(the punctuation)."
|
179
181
|
).send()
|
180
182
|
if f.options:
|
181
183
|
for o in f.options:
|
@@ -202,7 +204,8 @@ class ChatCommandProvider:
|
|
202
204
|
ans = "false"
|
203
205
|
|
204
206
|
if f.type.endswith("multi"):
|
205
|
-
|
207
|
+
choices = [] if ans == " " else ans.split("\n")
|
208
|
+
form_values[f.var] = f.validate(choices)
|
206
209
|
else:
|
207
210
|
form_values[f.var] = f.validate(ans)
|
208
211
|
result = await self.__wrap_handler(
|
@@ -292,7 +292,7 @@ class Unregister(Command):
|
|
292
292
|
user = self.xmpp.store.users.get(session.user_jid)
|
293
293
|
assert user is not None
|
294
294
|
await self.xmpp.unregister_user(user)
|
295
|
-
return "
|
295
|
+
return "You are not registered anymore. Bye!"
|
296
296
|
|
297
297
|
|
298
298
|
class LeaveGroup(Command):
|
@@ -797,6 +797,9 @@ class BaseGateway(
|
|
797
797
|
fut.set_exception(exception)
|
798
798
|
|
799
799
|
async def unregister_user(self, user: GatewayUser):
|
800
|
+
self.send_presence(
|
801
|
+
pshow="busy", pstatus="You are not registered to this gateway anymore."
|
802
|
+
)
|
800
803
|
await self.xmpp.plugin["xep_0077"].api["user_remove"](None, None, user.jid)
|
801
804
|
await self.xmpp.session_cls.kill_by_jid(user.jid)
|
802
805
|
|
@@ -374,9 +374,20 @@ class AttachmentMixin(TextMessageMixin):
|
|
374
374
|
if xmpp_id == original_xmpp_id:
|
375
375
|
continue
|
376
376
|
self.retract(xmpp_id, thread)
|
377
|
+
|
378
|
+
if reply_to is not None and reply_to.body:
|
379
|
+
# We cannot have a "quote fallback" for attachments since most (all?)
|
380
|
+
# XMPP clients will only treat a message as an attachment if the
|
381
|
+
# body is the URL and nothing else.
|
382
|
+
reply_to_for_attachment: MessageReference | None = MessageReference(
|
383
|
+
reply_to.legacy_id, reply_to.author
|
384
|
+
)
|
385
|
+
else:
|
386
|
+
reply_to_for_attachment = reply_to
|
387
|
+
|
377
388
|
msg = self._make_message(
|
378
389
|
when=when,
|
379
|
-
reply_to=
|
390
|
+
reply_to=reply_to_for_attachment,
|
380
391
|
carbon=carbon,
|
381
392
|
mto=mto,
|
382
393
|
thread=thread,
|
@@ -242,6 +242,10 @@ class Room(Base):
|
|
242
242
|
|
243
243
|
avatar_legacy_id: Mapped[Optional[str]] = mapped_column(nullable=True)
|
244
244
|
|
245
|
+
archive: Mapped[list["ArchivedMessage"]] = relationship(
|
246
|
+
cascade="all, delete-orphan"
|
247
|
+
)
|
248
|
+
|
245
249
|
|
246
250
|
class ArchivedMessage(Base):
|
247
251
|
"""
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
{slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/3071e0fa69d4_add_contact_client_type.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
{slidge-0.2.1 → slidge-0.2.2}/slidge/db/alembic/versions/82a4af84b679_add_muc_history_filled.py
RENAMED
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|