Menu

#75 Subfolders style required when for subfolders in hidden folders, despite use of `Flatten`

1.4.4
wont-fix
nobody
None
unknown
5
2024-07-30
2024-05-10
Erik Rogers
No

I encountered an error when syncing:

Maildir error: found subfolder '.notmuch/xapian', but store 'personal-local' does not specify SubFolders style

This is the relevant MaildirStore configuration, from .mbsyncrc:

MaildirStore personal-local
Path ~/Maildir/personal/
Inbox ~/Maildir/personal/Inbox
Flatten .

The error is complaining about a lack of configuration for subfolders style in a hidden folder created by the notmuch program in the base of the Maildir path. This is despite the documentation saying subfolder style is not required if Flatten is used.

SubFolders Verbatim|Maildir++|Legacy
The on-disk folder naming style used for hierarchical mailboxes. This option has no effect when Flatten is used.

I was able to "fix" it by adding Subfolders Verbatim to my configuration. But it seems like either the documentation should correctly describe the behavior, or even better, subfolders in hidden folders could also be ignored when Flatten is used.

Discussion

  • Oswald Buddenhagen

    you're making some rather unfounded assumptions.

    the documentation is actually entirely correct, when nothing external messes with the maildir structure. but of course it needs to know what to do with weird folders that appeared out of nowhere.

    dot files being hidden is just a convention, not something set in stone. and the nested maildirs clearly kinda disagree. it would be rather negligent to just ignore these folders.

     
  • Erik Rogers

    Erik Rogers - 2024-05-10

    Ah, I see, thanks for clearing up my confusion.

    It seems there is no restriction on naming convention for IMAP folders on dot character for hidden files, so technically mbsync should look there, and I was mistaken about hidden folders.

    However, it still seems strange to me that it tries to look in a subdirectory for a Maildir that is using Flatten. It would have been clearer to me if the documentation specified that mbsync would look in subdirectories despite setting Flatten (even when it doesn't create them itself), and that you may need to set the Subfolders value in that case.

     
  • Oswald Buddenhagen

    the question is then what happens next. i don't think real subfolders will be liked particularly well in an otherwise flattened hierarchy. i suppose an exclusion pattern or not using patterns in the first place works, but it's kinda dirty. (how) did you get it running?

     
  • Erik Rogers

    Erik Rogers - 2024-05-11

    I was able to fix it with the following configuration (add subfolder style to the store):

    MaildirStore personal-local
    Path ~/Maildir/personal/
    Inbox ~/Maildir/personal/Inbox
    Flatten .
    Subfolders Verbatim
    

    All I propose is that we update the documentation, from this:

    SubFolders Verbatim|Maildir++|Legacy
    The on-disk folder naming style used for hierarchical mailboxes. This option has no effect when Flatten is used.

    To this:

    SubFolders Verbatim|Maildir++|Legacy
    The on-disk folder naming style used for hierarchical mailboxes. This option has no effect when Flatten is used (when there are no subfolders).

    Does that sound good? I don't think we need any code changes, just make it clear that you may actually need to set subfolder style if subfolders are actually present, for any reason.

    Thanks so much for your help maintaining this project, by the way, the program is really great.

    Thanks,

    Erik

     
  • Oswald Buddenhagen

    but how would that help? without some background info this is just confusing. the user finding out through isync's complaint is equivalent to that.

    you already wrote that you fixed it that way. the question is how that "fix" fits into the bigger picture of the configuration.

     
  • Oswald Buddenhagen

    • status: reported --> wont-fix
     
  • Oswald Buddenhagen

    would not add value, as per previous discussion.

     

Log in to post a comment.

MongoDB Logo MongoDB