decode mailbox

This commit is contained in:
Antonio J. Delgado 2025-03-26 19:17:48 +02:00
parent 103b34120c
commit c1a4420744
3 changed files with 3 additions and 3 deletions

BIN
.test.conf.swp Normal file

Binary file not shown.

View file

@ -1,6 +1,6 @@
# backup_imap
Do a backup of an IMAP account in a folder.
Do a backup of an IMAP account in to a local folder.
## Requirements
@ -20,7 +20,7 @@ sudo ./install.sh --destination /usr/local/bin
Change your configuration file in "${HOME}/.config/backup_imap.conf" (see the example in the config folder).
### Windows (from PowerShell)
### Windows (from PowerShell, untested)
Ensure you have "C:\Users\${env:USERNAME}\AppData\Roaming\Python\Python${python_version}\Scripts\" in your Path environment variable.

View file

@ -68,7 +68,7 @@ class BackupImap:
if mailbox == '':
real_mailbox = 'INBOX'
else:
real_mailbox = mailbox
real_mailbox = mailbox.decode()
self.imap.select(mailbox=f"\"{real_mailbox}\"", readonly=False)
self._log.debug(
"Searching for all messages in '%s'...",