Bug 1588391 Comment 0 Edit History

Note: The actual edited comment in the bug view page will always show the original commenter’s name and original timestamp.

STR:

1) Create a folder with a space in it (uri e.g.: `imap://me%40example.com@imap.gmail.com/INBOX/with space`)
2) 
```
let folder = messenger.accounts.get("account1").folders.find(folder => folder.name == "with space");
messenger.mailTabs.update({ displayedFolder: folder });
```

Result:
`Folder "/INBOX/with space" for account "account1" not found.`

Expected:
Folder is correctly selected.

Addl Info:
The folder lookup service expects the folder path to be a string exact match to the folder uri already there. imap folders don't seem to escape spaces to %20, so the folder is not found.

I'm sensing there may be other edge cases, and it might even depend on the protocol type. When fixing this bug we should find out how to make sure we always use the correct path.

I'm marking this P1 since it breaks a bunch of APIs that work with folders (go to folder, copy/move messages to folders, etc). Geoff, do you have cycles to look into this?
STR:

1) Create a folder with a space in it (uri e.g.: `imap://me%40example.com@imap.gmail.com/INBOX/with space`)
2) Do something like this:
```javascript
let folder = await messenger.accounts.get("account1").folders.find(folder => folder.name == "with space");
await messenger.mailTabs.update({ displayedFolder: folder });
```

Result:
`Folder "/INBOX/with space" for account "account1" not found.`

Expected:
Folder is correctly selected.

Addl Info:
The folder lookup service expects the folder path to be a string exact match to the folder uri already there. imap folders don't seem to escape spaces to %20, so the folder is not found.

I'm sensing there may be other edge cases, and it might even depend on the protocol type. When fixing this bug we should find out how to make sure we always use the correct path.

I'm marking this P1 since it breaks a bunch of APIs that work with folders (go to folder, copy/move messages to folders, etc). Geoff, do you have cycles to look into this?
STR:

1) Create a folder with a space in it (`/INBOX/with space` for example)
2) Do something like this:
```javascript
let folder = await messenger.accounts.get("account1").folders.find(folder => folder.name == "with space");
await messenger.mailTabs.update({ displayedFolder: folder });
```

Result:
`Folder "/INBOX/with space" for account "account1" not found.`

Expected:
Folder is correctly selected.

Addl Info:
The API encodes the folder URI to `imap://me%40example.com@imap.gmail.com/INBOX/with%20space` while the real folder uri is `imap://me%40example.com@imap.gmail.com/INBOX/with space`. The folder lookup service expects the folder path to be a string exact match to the folder uri, not an uri match. imap folders don't seem to escape spaces to %20, so the folder is not found.

I'm sensing there may be other edge cases, and it might even depend on the protocol type. When fixing this bug we should find out how to make sure we always use the correct path.

I'm marking this P1 since it breaks a bunch of APIs that work with folders (go to folder, copy/move messages to folders, etc). Geoff, do you have cycles to look into this?

Back to Bug 1588391 Comment 0