Closed Bug 1816822 Opened 1 year ago Closed 1 year ago

On 112a imap sub-folders of an un-selectable folder (e.g., [Gmail]/) don't show the un-selectable folder [Gmail] as a parent folder

Categories

(Thunderbird :: Folder and Message Lists, defect)

Thunderbird 112
defect

Tracking

(thunderbird_esr102 unaffected)

RESOLVED WONTFIX
Tracking Status
thunderbird_esr102 --- unaffected

People

(Reporter: gds, Unassigned)

References

(Blocks 1 open bug, Regression)

Details

(Keywords: regression, Whiteboard: [Supernova3p])

Attachments

(4 files)

With self-built 112, folders under [Gmail] display one level up. For example

A
B
[Gmail]
  A
  B
C

displays as

A
B
A
B
C

The unselectable [gmail] folder does not display at all. So it looks like I have folders at the same level with duplicate names.

Keywords: regression
Whiteboard: [Supernova]
Regressed by: 1806922

We removed that ghost [Gmail] folder on purpose to make the folder pane behave more consistently across providers.
I don't see any duplicate folders, what are those?
Are those special folders like Trash or Drafts with proper icons?
How are those folders represented in Gmail?
Did you create those folders, or previously moved them outside the ghost [Gmail] folder, or maybe another program created them automatically?

Flags: needinfo?(gds)

They are not really duplicate folders, just folders with the same name at different levels.
I had created the folders myself months or years ago just for test purposes. I don't remember why. They currently have different content.

At gmail they show up as labels like:

gds
[Gmail]/gds

But when the "ghost" folder [Gmail] is gone from TB 112 they appear as two folders at the same level with the same name gds but with different content which looks like something is wrong even if it's not.

The workaround to only see folders under [Gmail] and hide the ghost has been to set the advance server setting "Imap server directory" to [Gmail] but it hides the folders at the same level as [Gmail] but you don't see possible duplicate folder names.

Flags: needinfo?(gds)

Note that there is also [Google Mail], and I'm assuming translated versions of it as well? https://bugzilla.mozilla.org/attachment.cgi?id=9319229

My gmail accounts - on a windows system account "A" I see two Trash folders, both with the "special" icon. And on Mac with account "B" I see two trash and two Sent, all with the "special" icon.

I see extra folders in 110 beta, but I didn't manually create the extras in either example - I assume they were created by an iphone or older instance of Thunderbird.

My gmail accounts - on a windows system account "A" I see two Trash folders, both with the "special" icon.

That's another regression of mailnews.imap.jsmodule=true. I filed bug 1818589 for that.

https://searchfox.org/comm-central/rev/0f29df3556018ea0dbbb4d6c862f06a26d8f9209/mail/base/content/about3Pane.js#989-991
Note that there is also [Google Mail]

Will this be handled in this Bugzilla ticket as well or is there another one for this / should be filed? Since I am affected by this I want to know where I have to follow. :)

I think this is a WONTFIX if it was caused by manual creation of folders.

This could result in surfacing hidden folders that people or apps had created previously and users didn't realize were there, though. I'm not really sure if that's a problem we can solve or how widespread it might be.

See Also: → 1818592

Not sure why but my gray [Gmail] imap folder is back with a self-build C-C with tip at 38480:7b52c222b4a0, which, to me, is good. I don't think the folder structure that users are used to seeing should change spontaneously.

Think it was changed in bug 1818592.

Ok, pulled in the latest C-C and now I'm NOT seeing the [Gmail] unselectable subfolder again. And, as originally noticed, I see folders at the same level with identical names but with different content.

Also, when I look at subscribe (right-click dialog), I still see the gray folder [Gmail] (not subscribable) and I see the sub-folders under it that are promoted up a level in the newest folder tree view.

I think this new gmail flat folder tree view should be made a user selectable setting that defaults to the current (v102) view showing [Gmail] and its sub-folders to avoid possible folders with the same name at the same level. Also, maybe not a good idea to change the gmail folder view that most users are now used to.

(In reply to Andrei Hajdukewycz [:sancus] from comment #8)

I think this is a WONTFIX if it was caused by manual creation of folders.

This could result in surfacing hidden folders that people or apps had created previously and users didn't realize were there, though. I'm not really sure if that's a problem we can solve or how widespread it might be.

My folders with the same name were not "hidden" and I did realize they were there.

Whiteboard: [Supernova] → [Supernova3p]

We want to keep the flat folder hierarchy and ignore the [Gmail] ghost folder.
Marking this as WONTFIX, but if there are other problems, like missing folders or incorrect hierarchy, please open another dedicated bug.

Status: NEW → RESOLVED
Closed: 1 year ago
Resolution: --- → WONTFIX

If this is not a bug then it at least needs a release note telling users that they may see folders with the same name at the same level, as illustrated in comment 0.
Also, the subscribe dialog still shows [Gmail] folder and the folders under it. Not sure if subscribe dialog should be "flat" too.

See Also: → 1835891

(In reply to Alessandro Castellani [:aleca] from comment #12)

We want to keep the flat folder hierarchy and ignore the [Gmail] ghost folder.
Marking this as WONTFIX, but if there are other problems, like missing folders or incorrect hierarchy, please open another dedicated bug.

Please read bug 1835891
It refers to beta 116*
Creating a imap gmail account creates non imap pop type files which obviously are not server folders and never display, but they get created an put into imap.gmail.com profile folder. They have to manually deleted from profile after creating imap gmail mail account.
With the exception of Inbox, all folders/files get stored in a [Gmail].sbd folder which is in imap.gmail.com - not wanted as it causes display problems eg: Subfolders do not get displayed under the correct folder as a duplicate NoSelect italic folder is created for them which is not wanted. All top level files/folders should be in imap.gmail.com but I only get Inbox plus a load of files that are not even imap files.

Set 'IMAP server directory : [Gmail]' - this is left blank by default and therefore causes a display problem, so after creating account you have to set this setting and restart which gets rid of the NoSelect folder, but then subfolders appear as top level folders despite profile folders now fully corrected - This sounds like the issue mentioned for this bug.

Then you perform another restart without needing to do anything and finally the Folder Pane respects what is in the profile folders.

As part of creating a gmail mail account, I do feel it should not be necessary to delete incorrectly created files, modify Imap server directory to get rid of [Gmail].sbd and restart several times just to get a correct set of files in Profile and a correct display in Folder Pane.

Full details of bug 1835891 includes some images showing what is going on.

Depends on: 1818592
See Also: 1818592
Summary: On 112a imap sub-folders of an un-selectable folder (e.g., [Gmail]/) don't show the un-selectable folder → On 112a imap sub-folders of an un-selectable folder (e.g., [Gmail]/) don't show the un-selectable folder [Gmail] as a parent folder
Duplicate of this bug: 1847449

(At least for one of my accounts) I discovered the [Gmail] parent folder will be shown in Thunderbird if I mark the checkbox Show in IMAP in the gmail account web interface.

Adds a new pref mail.hide_gmail_ghost (default to true) to allow
the [Gmail] or [Google Mail] non-selectable folder to remain visible
as in 102 and earlier. I'm fairly sure this is part of the problem
described here: https://support.mozilla.org/en-US/questions/1426444
Note: This patch is something I did several months ago just to see if it would work. I had to merge it into the current daily but it still works OK.
If you change the pref mail.hide_gmail_ghost you have to restart for it to take effect.

I'm now 99% sure the support issue at https://support.mozilla.org/en-US/questions/1426444 illustrates the problem since I can now duplicate the bug:
I have 3 folders at different location all named top-level-imap:
imap://gd.smth%40gmail.com@imap.gmail.com/%5Bxxx%5D/top-level-imap
imap://gd.smth%40gmail.com@imap.gmail.com/%5BGmail%5D/top-level-imap
imap://gd.smth%40gmail.com@imap.gmail.com/%5Bimap%5D/top-level-imap

Interpreting the % escape chars, the folders are located under non-selectable (grey/ghost) folders:
[xxx]
[Gmail]
[Imap]
And all 3 top-level-imap folders appear in the folder tree at the same level, as reported in the support issue.

One issue in the current code is that instead looking for the string "[Gmail]" or "[Google Mail]" to identify the folder to hide, the code hides any folder that has the "No Select" flag: https://searchfox.org/comm-central/rev/858177c2fb44144f06f288ccd39c332ea91a0302/mail/base/content/about3Pane.js#2297

However, I don't think making the hiding specific by folder name will resolve the support issues. What it really needs is a way to optionally still show all the folders and not try to hide them at all as my WIP/proposed patch in comment 17 does.

After more consultation with the user over at https://support.mozilla.org/en-US/questions/1426444 I see what the problem is. An example folder URI (from folder properties) is this:

imap://suthers%40hawaii.edu@imap.gmail.com/TRACES/Administrative

The folder TRACES is a "noselect" folder that was create long ago in the gmail account by the support user. The current code only looks for folders that are "noselect" to hide. So TRACES gets hidden (as well as [Gmail] and {Google Mail]). Since the user has several other "noselect" folders with sub-folders called "Administrative" he ends up with several "Administrative" folders all at the same level and with their container/noselect folders hidden.

Note: It's easy to create a noselect folder TRACES in gmail by just creating, e.g., TRACES/Admin at the top level. With 115 you will only see folder Admin appear. But the location property will be, e.g.:

imap://w4k9vws%40gmail.com@imap.gmail.com/TRACES/Admin

So as a minimum the code needs to only hide folders named explicitly [Gmail] or[Google Mail] (which are also noselect folders) instead of all noselect folders. However, it also needs an option to not hide anything as I've implemented in patch at comment 17.

(In reply to Wayne Mery (:wsmwk) from comment #16)

Created attachment 9362054 [details]
Screenshot 2023-11-05 at 12.23.44 PM.png

(At least for one of my accounts) I discovered the [Gmail] parent folder will be shown in Thunderbird if I mark the checkbox Show in IMAP in the gmail account web interface.

That must somehow be setting folder [Gmail] to be selectable since the code doesn't look at the exact folder name but only if the folder has the noselect flag.
After doing this, did [Gmail] show up in normal font (selectable folder) or gray (noselect folder)?

(In reply to gene smith from comment #20)

(In reply to Wayne Mery (:wsmwk) from comment #16)

Created attachment 9362054 [details]
Screenshot 2023-11-05 at 12.23.44 PM.png

(At least for one of my accounts) I discovered the [Gmail] parent folder will be shown in Thunderbird if I mark the checkbox Show in IMAP in the gmail account web interface.

That must somehow be setting folder [Gmail] to be selectable since the code doesn't look at the exact folder name but only if the folder has the noselect flag.
After doing this, did [Gmail] show up in normal font (selectable folder) or gray (noselect folder)?

Normal font / selectable :)

So as a minimum the code needs to only hide folders named explicitly [Gmail] or[Google Mail] (which are also noselect folders) instead of all noselect folders. However, it also needs an option to not hide anything as I've implemented in patch at comment 17.

I agree that the default behavior should be to only flatten [Gmail] and [Google Mail]. There have been some complaints about flattening those folders, but I'm not sure a preference should be provided to allow the user to "undo" the standardization provide by bug 1818592.

https://connect.mozilla.org/t5/discussions/the-new-update-has-completely-ruined-my-user-experience-with/m-p/40680 seems to describe this behavior?

One thing I don't understand, is why for my gmail accounts my other parent folders don't have problems but other users do have problems, like Dan. Looking at my gmail settings I see Show in IMAP is enabled, but I don't remember ever setting that. (not remembering doesn't necessarily mean anything)

(In reply to Wayne Mery (:wsmwk) from comment #21)

(In reply to gene smith from comment #20)

(In reply to Wayne Mery (:wsmwk) from comment #16)

Created attachment 9362054 [details]
Screenshot 2023-11-05 at 12.23.44 PM.png

(At least for one of my accounts) I discovered the [Gmail] parent folder will be shown in Thunderbird if I mark the checkbox Show in IMAP in the gmail account web interface.

That must somehow be setting folder [Gmail] to be selectable since the code doesn't look at the exact folder name but only if the folder has the noselect flag.
After doing this, did [Gmail] show up in normal font (selectable folder) or gray (noselect folder)?

Normal font / selectable :)

So as a minimum the code needs to only hide folders named explicitly [Gmail] or[Google Mail] (which are also noselect folders) instead of all noselect folders. However, it also needs an option to not hide anything as I've implemented in patch at comment 17.

I agree that the default behavior should be to only flatten [Gmail] and [Google Mail]. There have been some complaints about flattening those folders, but I'm not sure a preference should be provided to allow the user to "undo" the standardization provide by bug 1818592.

The pref would only undo the current hiding of noselect folders for those users that are having problems with the new behavior. Of course, probably most user won't even notice the change or care how it works.

https://connect.mozilla.org/t5/discussions/the-new-update-has-completely-ruined-my-user-experience-with/m-p/40680 seems to describe this behavior?

I think that's what it is since they talk about the hidden [Gmail] folder. But most of the complaints I don't exactly follow.

One thing I don't understand, is why for my gmail accounts my other parent folders don't have problems but other users do have problems, like Dan. Looking at my gmail settings I see Show in IMAP is enabled, but I don't remember ever setting that. (not remembering doesn't necessarily mean anything)

It depends on how you initially created the folders. In TB, if you create the folder:

hidden/valley

hidden will be a noselect and won't appear in 115 you just see valley.
But If you create folder

hidden

with no trailing slash, and then create

hidden/valley

both hidden and valley will be normal (selectable) folders.

I tried your idea about setting [Gmail] label to show in imap. At gmail, for me, I didn't have a label called just [Gmail] listed so I had to create it. When I restart TB, I now see the [Gmail] folder (no longer noselect so normal font) and everything under it listed as with 102. So to fix the issues, in gmail, create new labels for each of the hidden (noselect) folders and they will appear in tb after a restart (the "show in imap" setting seems to be on by default when you create a new label). It's a pain to have to do this, but it is a work-around to fix the issues with current 115.

Attached image gmail-webmail.jpg

In beta 121.0b1
It is not possible to show any noselect folder unless you create a double no select.
I do not want to see the [Gmail] no select folder as it causes a messy view and subfolders to Inbox end up under a separate INBOX no select folder and not as subfolders to the real Inbox.
But I do want to see any noselect folder I created.

How to fix
Access gmail webmail account
If you do not have a label called [Gmail]/ then create it.
All other labels you created would be 'sub' to [Gmail]/

created a label called Testing/ as sub to [Gmail]
Then created a label called Testing/Test sub as a sub to Testing/
All are set to show in Imap.

In Thunderbird 121.0b1 I see:
'Testing' as a noselect folder containing Sub Test which is a normal folder.

In the 'Subscribe' list it looks like this:

Testing - italic no select - set to subscribe

Testing - italic no select - set to subscribe

Sub Test normal set to subscribe

Testing_ - set as Unsubscribe

What I see in Folder Pane

Testing - italic no select - set to subscribe

Sub Test normal set to subscribe

If you want to see the no_select then you need to create a double no select then the code blocks the first but not the second.
posted as additional image

Attached image gmail-noselect.jpg

This shows the Subscribe list and the Folder Pane.

Notice: you need to effectively create a double noselect then the current TB code may stop the first noselect but it doesn't stop the second.
So no select can be created, but you have to know what to do in the gmail webmail account hence why I posted image showing contents.

Attachment #9362064 - Attachment description: WIP: Bug 1816822 - Disable hiding of [Gmail] folder via pref → Bug 1816822 - Disable hiding of [Gmail] and other top level no-select folders with a new pref. r=aleca

(In reply to gene smith from comment #17)

Created attachment 9362064 [details]
Bug 1816822 - Disable hiding of [Gmail] and other top level no-select folders with a new pref. r=aleca

Since there were no comments on the WIP/draft I submitted a few weeks ago, I'm going ahead and requesting a review on this. I'm sure it's probably not an optimal fix but it did work when I tried it. Also, it still contains some debug dumps that I left in it for now.

You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: