As in subject, if you for instance create a simple passwd-file with:
test@domain.tld:{plain}pass:20000:10::/home/regular/.test::userdb_mail=maildir:%h/maildir
Dovecot (rc23 & 27) will expand %h to empty string, and try to make a directory under /
Mar 14 14:25:28 rasengan dovecot: IMAP(test@domain.tld): mkdir(/maildir/cur) failed: Permission denied Mar 14 14:25:28 rasengan dovecot: IMAP(test@domain.tld): mkdir(/maildir/.Trash/cur) failed: Permission denied ...
If tilde is used instead of %h, the expansion works properly.
While checking it, I tested other variables (putting aside craziness of using some of them), so summing it up - h,w,i,a,b don't work, all the other ones do.
In case %h is not actually intended to work in passwd-files, some wiki examples would have to be adjusted.