Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Attachments filenames #70

Merged
merged 8 commits into from
Dec 20, 2024
Merged

Conversation

Era-Dorta
Copy link
Collaborator

This PR builds on top of #67 and makes accessible the files of the attachments. One use case of this is to delete the files after they've been received. Both to avoid running out of space in the hard drive and because if the chat has an expiration date, the files should be automatically removed after that time. The second is for now theoretical, as the rest-api does not support yet the message expiration, there was a PR that added that but it was never merged.

I think the best solution for attachments is to have a class that makes all the attributes available to the bot. However, that is a bit of a big ask for now. For inspiration, I did exactly that in the semaphore repo lwesterhof/semaphore#51

tests/test_message.py Outdated Show resolved Hide resolved
@Era-Dorta Era-Dorta merged commit f7b0a03 into filipre:master Dec 20, 2024
2 checks passed
@Era-Dorta Era-Dorta deleted the attachments-filenames branch December 20, 2024 15:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant