Module download

Module download 

Source
Expand description

Β§Download large messages manually.

ModulesΒ§

post_msg_metadata πŸ”’

EnumsΒ§

DownloadState
Download state of the message.

ConstantsΒ§

MIN_DELETE_SERVER_AFTER πŸ”’
If a message is downloaded only partially and delete_server_after is set to small timeouts (eg. β€œat once”), the user might have no chance to actually download that message. MIN_DELETE_SERVER_AFTER increases the timeout in this case.
PRE_MSG_ATTACHMENT_SIZE_THRESHOLD πŸ”’
From this point onward outgoing messages are considered large and get a Pre-Message, which announces the Post-Message. This is only about sending so we can modify it any time. Current value is a bit less than the minimum auto-download setting from the UIs (which is 160 KiB).
PRE_MSG_SIZE_WARNING_THRESHOLD πŸ”’
Max size for pre messages. A warning is emitted when this is exceeded.

FunctionsΒ§

available_post_msgs_contains_rfc724_mid πŸ”’
delete_from_available_post_msgs πŸ”’
delete_from_downloads πŸ”’
download_known_post_messages_without_pre_message πŸ”’
Downloads known post-messages without pre-messages in order to guard against lost pre-messages.
download_msg πŸ”’
Actually download a message partially downloaded before.
download_msgs πŸ”’
msg_is_downloaded_for πŸ”’
set_state_to_failure πŸ”’