Thunderbird creates an empty "thunderbird" folder in the home directory
Categories
(Toolkit :: Startup and Profile System, defect)
Tracking
()
| Tracking | Status | |
|---|---|---|
| firefox-esr140 | --- | unaffected |
| firefox-esr153 | --- | wontfix |
| firefox152 | --- | wontfix |
| firefox153 | --- | wontfix |
| firefox154 | --- | fixed |
People
(Reporter: contact, Assigned: gerard-majax)
References
(Regression)
Details
(Keywords: regression)
Attachments
(3 files, 1 obsolete file)
User Agent: Mozilla/5.0 (X11; Linux x86_64; rv:148.0) Gecko/20100101 Firefox/148.0
Steps to reproduce:
I opened Thunderbird (currently 147.0b3).
Actual results:
For the last week or so, opening Thunderbird creates an empty "Thunderbird" folder in my Linux home directory (~).
Expected results:
No folder should be created, as it always been before.
Comment 1•9 months ago
|
||
TB146.0.1, OpenSuse Linux
I can confirm this behavior. When deleting the Thunderbird folder in the home directory it will be recreated.
I'm not seeing this on Windows.
Updated•9 months ago
|
That's the end of mozregression --app thunderbird --bad 147 --good 146
INFO: No more integration revisions, bisection finished.
INFO: Last good revision: 4c95576f4aaf10be3c779dbcfcccfbcea0d6278c
INFO: First bad revision: 34f7a0ab2366ba11b7b5133dd656d83f34a71db9
INFO: Pushlog:
https://hg.mozilla.org/comm-central/pushloghtml?fromchange=4c95576f4aaf10be3c779dbcfcccfbcea0d6278c&tochange=34f7a0ab2366ba11b7b5133dd656d83f34a71db9
Seems unrelated though. Maybe the second to last step is more helpful:
Narrowed integration regression window from [252560d0, 0628d206] (4 builds) to [4c95576f, 0628d206] (3 builds) (~1 steps left)
INFO: Pushlog:
https://hg.mozilla.org/comm-central/pushloghtml?fromchange=4c95576f4aaf10be3c779dbcfcccfbcea0d6278c&tochange=0628d20688a326abe107d83e9075c86767b98e4a
Comment 3•9 months ago
|
||
Well, it is almost certainly something from mozilla-central, so please note down the changesets from there (Thunderbird builds from c-c + m-c)
Attached to full mozregression output. I hope it contains the information you're looking for.
Pushlog from mozilla-central for the same date:
https://hg-edge.mozilla.org/mozilla-central/pushloghtml?fromchange=e4b3aaadb10a910e2cceb178858d6650fd7fb5c8&tochange=a7ab407c4b2f588b662a5f6f0a01ec194ddf0e2a
My guess is that it is related to the xdg changes from bug 259356
Comment 6•8 months ago
|
||
Yeah, surely from bug 259356
Comment 7•8 months ago
•
|
||
Yes. It's related to the change upstream. They had a similar issue in bug 2001887
Updated•8 months ago
|
Comment 8•8 months ago
|
||
I certainly agree that this was caused by the XDG changes. It was already fixed in Firefox 147.0.1:
https://www.firefox.com/en-US/firefox/147.0.1/releasenotes/
(In reply to Nathan Zachary from comment #8)
It was already fixed in Firefox 147.0.1:
Issue is still present in thunderbird 147.0.1
Comment 10•8 months ago
|
||
Present in 145.0 (64-bit) on Arch Linux.
$ cat user-dirs.dirs
# This file is written by xdg-user-dirs-update
# If you want to change or add directories, just edit the line you're
# interested in. All local changes will be retained on the next run.
# Format is XDG_xxx_DIR="$HOME/yyy", where yyy is a shell-escaped
# homedir-relative path, or XDG_xxx_DIR="/yyy", where /yyy is an
# absolute path. No other format is supported.
#
XDG_DESKTOP_DIR="$HOME/"
XDG_DOWNLOAD_DIR="$HOME/"
XDG_TEMPLATES_DIR="$HOME/"
XDG_PUBLICSHARE_DIR="$HOME/"
XDG_DOCUMENTS_DIR="$HOME/"
XDG_MUSIC_DIR="$HOME/"
XDG_PICTURES_DIR="$HOME/"
XDG_VIDEOS_DIR="$HOME/"
Comment 11•8 months ago
|
||
Present in 147.0.1 (64-bit) on Linux Mint 22.1 based on Ubuntu 24.04
> cat /etc/lsb-release
DISTRIB_ID=LinuxMint
DISTRIB_RELEASE=22.1
DISTRIB_CODENAME=xia
DISTRIB_DESCRIPTION="Linux Mint 22.1 Xia"
> cat /etc/upstream-release/lsb-release
DISTRIB_ID=Ubuntu
DISTRIB_RELEASE=24.04
DISTRIB_CODENAME=noble
DISTRIB_DESCRIPTION="Ubuntu Noble Numbat"
Comment 12•8 months ago
|
||
Present in 147.0.1 (64-bit) on NixOS 26.05 (Yarara)
Comment 13•8 months ago
|
||
(In reply to Nathan Zachary from comment #8)
I certainly agree that this was caused by the XDG changes. It was already fixed in Firefox 147.0.1:
https://www.firefox.com/en-US/firefox/147.0.1/releasenotes/
I think that was referring to a different issue. Firefox 147 was creating an unneeded ~/.mozilla/extensions folder, which has been fixed in firefox and thunderbird 147.0.1. This issue may also be related to the xdg changes, but it might also not be.
Comment 14•7 months ago
|
||
Present in 147.0.2 (64-bit) on openSUSE tumbleweed
Comment 15•7 months ago
|
||
Present in 147.0.1 (64-bit) on Arch Linux
Comment 16•7 months ago
|
||
(In reply to spamgrinder+mozilla from comment #11)
Still present in 147.0.2 (64-bit). Same system details.
Comment 17•7 months ago
|
||
Present in 147.0 on Fedora 43 (in today's upgrade).
Comment 18•7 months ago
|
||
Same on Fedora 42 since TB 147: https://bugzilla.redhat.com/show_bug.cgi?id=2441002
Comment 19•7 months ago
|
||
funny: TB creates a folder name "Projects" too ... WTF?
Comment 20•7 months ago
|
||
The prior logic always evaluated the if statement to true because
target_is_windows was a non-none object.
Updated•7 months ago
|
Updated•7 months ago
|
Comment 21•7 months ago
|
||
(In reply to Corey Bryant from comment #20)
Created attachment 9546893 [details]
Bug 2007074 - Ensure proper logic for setting MOZ_APP_PROFILE. r=#thunderbuildThe prior logic always evaluated the if statement to true because
target_is_windows was a non-none object.
Without patching we get ~/Thunderbird
With the proposed patch on top of thunderbird-147.0.2, it still creates a ~/thunderbird directory (still wrong directory, but now lower case)
What we should end up with is ~/.thunderbird
Comment 22•7 months ago
|
||
Actually... in an ideal world, we would probably end up with ~/.config/thunderbird O:-)
Comment 23•7 months ago
|
||
(In reply to Nico from comment #22)
Actually... in an ideal world, we would probably end up with ~/.config/thunderbird O:-)
Or more specifically: $XDG_CONFIG_HOME/thunderbird
| Comment hidden (off-topic) |
Comment 25•7 months ago
|
||
Pushed by benc@thunderbird.net:
https://hg.mozilla.org/comm-central/rev/22b7d2988a76
Ensure proper logic for setting MOZ_APP_PROFILE. r=dandarnell
Comment 27•7 months ago
|
||
More work is needed to handle empty ~/thunderbird directory
Comment 29•7 months ago
|
||
(In reply to jazztickets from comment #23)
(In reply to Nico from comment #22)
Actually... in an ideal world, we would probably end up with ~/.config/thunderbird O:-)
Or more specifically: $XDG_CONFIG_HOME/thunderbird
With a fallback to $HOME/.config.
Comment 30•7 months ago
|
||
Thunderbird version 147.0.1 (64-bit) creates $HOME/Thunderbird.
Creating cross-platform directories isn't trivial. My text editor uses the following code, which is still lacking, but never creates a directory in the user's home directory.
https://repo.autonoma.ca/repo/keenwrite/blob/HEAD/src/main/java/com/keenwrite/io/UserDataDir.java
Comment 31•7 months ago
|
||
Still an issue in TB 148.03 in Fedora 43.
Comment 32•7 months ago
|
||
Still an issue in TB 148.0 in NixOS
Comment 33•7 months ago
|
||
Same issue with Thunderbird 148.0 on Manjaro... why does it keep creating a folder in home even after I delete it? is there any temporary workaround?
Updated•6 months ago
|
Comment 34•6 months ago
|
||
(In reply to seven from comment #33)
Same issue with Thunderbird 148.0 on Manjaro... why does it keep creating a folder in home even after I delete it? is there any temporary workaround?
WORKAROUND: Hide the folder.
Comment 35•6 months ago
|
||
For those using GNOME, Xfce, Cinnamon, or anything else where the file manager uses GVFS (and this seems to also be recognized by KDE's Dolphin), files and folders can be hidden by listing them in a file named .hidden in the same directory (one name per line). For example:
echo Thunderbird >> ~/.hidden
will make the file manager hide the folder ~/Thunderbird as if it were a dot-dir.
Comment 36•6 months ago
|
||
This workaround of the ~/.hidden file doesn't work with PCManFM or PCManFM-qt. It could be that it's a feature of the Desktop Environment and not specifically the file manager, but I can't say with certainty. I'm not using any DE, but rather just a Window Manager. Hopefully, though, this regression will be fixed sooner rather than later so we won't have to use any type of workaround.
Comment 37•6 months ago
|
||
(In reply to brian from comment #34)
WORKAROUND: Hide the folder.
In linux as far as I know there's no way to hide a folder or a file unless it starts with a . eg: .Thunderbird instead of Thunderbird, but then a new visible Thunderbird folder will just be recreated on launch again. Ergo the need for this bug report. However... (see below response)
(In reply to grawity from comment #35)
For those using GNOME, Xfce, Cinnamon, or anything else where the file manager uses GVFS (and this seems to also be recognized by KDE's Dolphin), files and folders can be hidden by listing them in a file named
.hiddenin the same directory (one name per line). For example:echo Thunderbird >> ~/.hiddenwill make the file manager hide the folder
~/Thunderbirdas if it were a dot-dir.
YOU SIR are a genius though! I never knew about this! I tried it and it actually worked! 🤠 It's supposed to be a GNOME thing but as you said it works in KDE dolphin too! Thank you so much! 😁👍🏻
Comment 38•6 months ago
|
||
With Mozilla Thunderbird 149.0.1 on arch linux, the folder being created is now lower-case thunderbird instead of upper case Thunderbird.
Comment 39•6 months ago
|
||
Indeed. and this is much worse than before, as this breaks xdg-email. This is probably a weakness of xdg-email, but the directory in $HOME using the same name as the binary overlap it:
$ LC_ALL=C.UTF-8 xdg-email
awk: warning: command line argument `-' is a directory: skipped
/usr/bin/xdg-email: line 737: /home/casta/thunderbird: Is a directory
Comment 40•6 months ago
|
||
(In reply to brianmercer from comment #38)
With Mozilla Thunderbird 149.0.1 on arch linux, the folder being created is now lower-case thunderbird instead of upper case Thunderbird.
Confirming the same on Linux Mint: Thunderbird 149.0.1 (64-bit),Linux Mint 22.1 Xia based on Ubuntu 24.04 Noble
Comment 41•6 months ago
|
||
Environment:
OS: Arch Linux (Rolling)
DE: KDE Plasma 6.6.3
Thunderbird Version: 149.0.1 (Development build)
Observed Behavior:
I am confirming that the empty folder recreation bug persists in version 149.0.1. On my system, the application appears to alternate between variants: if I delete ~/Thunderbird, it eventually creates ~/thunderbird (lowercase), or vice versa. Both variants sometimes appear simultaneously after a restart.
This indicates that the directory-handling logic in the 149.x branch is still incorrectly targeting the home root instead of following hidden XDG paths. As an Arch user on the bleeding edge, I can confirm the current patches have not yet resolved this for my environment.
Comment 42•6 months ago
|
||
149.0.1 (64-bit)
Arch Linux.
https://wiki.archlinux.org/title/XDG_Base_Directory
This ~/thunderbird (or ~/Thunderbird) directory is always empty, so I'm not sure why it's even needed.
If it's for config, use XDG_CONFIG_HOME. If data, use XDG_DATA_HOME. If runtime info, use XDG_RUNTIME_DIR.
$ cat .config/user-dirs.dirs
XDG_DESKTOP_DIR="$HOME/"
XDG_DOWNLOAD_DIR="$HOME/"
XDG_TEMPLATES_DIR="$HOME/"
XDG_PUBLICSHARE_DIR="$HOME/"
XDG_DOCUMENTS_DIR="$HOME/"
XDG_MUSIC_DIR="$HOME/"
XDG_PICTURES_DIR="$HOME/"
XDG_VIDEOS_DIR="$HOME/"
If you are using any one of those, please let us know which one.
Comment 43•6 months ago
|
||
I experience the same bug on Arch Linux + KDE Plasma (but always with ~/thunderbird with a lowercase initial letter) with $XDG_CONFIG_HOME unset (but setting $XDG_CONFIG_HOME to $HOME/.config doesn’t change a thing).
Note that yesterday a weird and tiny stdin.xkm file was created in my home folder , and today an also tiny ta file was created, not sure if it’s related?
Updated•6 months ago
|
Comment 44•6 months ago
|
||
I think it is a bug in the crash reporting, this is an example from my strace
3577-wait4(19429, [{WIFEXITED(s) && WEXITSTATUS(s) == 0}], 0, NULL) = 19429 <0.047731>
3578---- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_EXITED, si_pid=19429, si_uid=1001, si_status=0, si_utime=0, si_stime=1 /* 0.01 s */} ---
3579-close(8<UNIX:[188039->188038]>) = 0 <0.000029>
3580-close(6<UNIX:[188037->188036]>) = 0 <0.000107>
3581:access("/home/meowxiik/Thunderbird", F_OK) = -1 ENOENT (No such file or directory) <0.000026>
3582-access("/home/meowxiik/mozilla", F_OK) = -1 ENOENT (No such file or directory) <0.000025>
3583:mkdir("/home/meowxiik/Thunderbird", 0700) = 0 <0.000204>
3584:access("/home/meowxiik/Thunderbird", F_OK) = 0 <0.000025>
3585-mkdir("/home/meowxiik/.thunderbird", 0700) = -1 EEXIST (File exists) <0.000031>
3586-mkdir("/home/meowxiik/.thunderbird/Crash Reports", 0700) = -1 EEXIST (File exists) <0.000052>
3587-mkdir("/home/meowxiik/.thunderbird/Crash Reports/events", 0700) = -1 EEXIST (File exists) <0.000031>
3588-mkdir("/home/meowxiik/.thunderbird/Crash Reports", 0700) = -1 EEXIST (File exists) <0.000072>
Before accessing ~/.thunderbird, creates the ~/Thunderbird
Comment 45•5 months ago
|
||
Just installed the latest version (150.0) on Arch Linux and the bug is still present.
Comment 46•5 months ago
|
||
(In reply to Petr B. from comment #45)
Just installed the latest version (150.0) on Arch Linux and the bug is still present.
I confirm.
KDE plasma: 6.6.4
KDE frameworks: 6.25.0
Qt:6.11.0
Kernel: 6.19.14
Wayland
Comment 47•5 months ago
|
||
Can confirm it still happens. Small thing, but a bit irksome as I use yazi and can't properly hide it.
Asahi Linux, Fedora 44, Hyprland
Thunderbird 149.0.1
Kernel: 6.19.13-400.asahi.fc44.aarch64+16k aarch64
Comment 48•5 months ago
|
||
Same problem but with a small t.
I'm on Fedora 44 Gnome. Thunderbird 149.0.1 installed through Fedora rpm repo.
Comment 49•5 months ago
|
||
Guys, EVERYONE has this problem. You don't need to post every os and tb combination, it's a BUILD-IN SELFMADE TB issue.
Comment 50•5 months ago
|
||
(In reply to support from comment #49)
Guys, EVERYONE has this problem. You don't need to post every os and tb combination, it's a BUILD-IN SELFMADE TB issue.
What would help then, is to provide visibility on how this bug is taken care of. Thanks.
Comment 51•5 months ago
|
||
Here's what happens in 150.0.1. Call path:
main() at comm/mail/app/nsMailApp.cpp:432
do_main() at comm/mail/app/nsMailApp.cpp:236
XRE_main() at toolkit/xre/nsAppRunner.cpp:6317
XREMain::XRE_main() at toolkit/xre/nsAppRunner.cpp:6219
XREMain::XRE_mainStartup() at toolkit/xre/nsAppRunner.cpp:5050
NS_GetToolkitProfileService() at toolkit/profile/nsToolkitProfileService.cpp:2919
nsToolkitProfileService::Init() at toolkit/profile/nsToolkitProfileService.cpp:997
nsXREDirProvider::GetUserAppDataDirectory() at toolkit/xre/nsXREDirProvider.h:64
Unwanted ~/thunderbird directory is created by GetUserDataDirectoryHome() first at line 1262.
Then correct ~/.thunderbird directory is created by EnsureDirectoryExists() at line 1269.
More specifically, unwanted ~/thunderbird is created by:
GetUserDataDirectoryHome() => GetLegacyOrXDGHomePath() => EnsureDirectoryExists() at line 1544.
Comment 52•4 months ago
|
||
As a workaround I copied my desktop file and changed the Exec line:
Exec=sh -c 'thunderbird %u & sleep 1; rmdir "$HOME/thunderbird" 2>/dev/null; fg'
Comment 53•4 months ago
|
||
I'm looking into this. While a workaround may be possible, we should get Thunderbird onboard for XDG support.
Comment 54•4 months ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #53)
I'm looking into this. While a workaround may be possible, we should get Thunderbird onboard for XDG support.
That would be incredibly beautiful! Maybe all of Mozilla would follow? Just dreaming...
Comment 55•4 months ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #53)
I'm looking into this. While a workaround may be possible, we should get Thunderbird onboard for XDG support.
Thanks! That would be great. Meanwhile I'm using Johannes' solution.
Comment 56•4 months ago
|
||
Firefox already did. That's why have this bug atm...
Comment 57•4 months ago
|
||
(In reply to arto+github from comment #48)
Same problem but with a small t.
I'm on Fedora 44 Gnome. Thunderbird 149.0.1 installed through Fedora rpm repo.
I switched to release channels flatpak which doesn't seem to have the problem.
Comment 58•4 months ago
|
||
(In reply to Magnus Melin [:mkmelin] from comment #56)
Firefox already did. That's why have this bug atm...
Awesome! I'm using LibreWolf but didn't even notice. Thanks for your help and work!
Comment 59•4 months ago
|
||
Comment 60•4 months ago
|
||
Thank you. Just rebuilt thunderbird 150.0.2 with this patch applied :
- no more empty folder created
- no loss of configuration
Works for me !
Updated•4 months ago
|
Comment 61•4 months ago
|
||
The severity field is not set for this bug.
:nika, could you have a look please?
For more information, please visit BugBot documentation.
Updated•4 months ago
|
Comment 62•4 months ago
|
||
fresh install 151.0 on manjaro, official repos, kde plasma
~/thunderbird still being created at every restart of thunderbird
Comment 63•3 months ago
|
||
(In reply to Ilja Rogoff from comment #62)
fresh install 151.0 on manjaro, official repos, kde plasma
~/thunderbird still being created at every restart of thunderbird
and still with 152
Updated•3 months ago
|
| Assignee | ||
Comment 64•3 months ago
|
||
Updated•3 months ago
|
Updated•3 months ago
|
Updated•3 months ago
|
Comment 65•3 months ago
|
||
Comment 66•3 months ago
|
||
| bugherder | ||
Updated•3 months ago
|
Updated•3 months ago
|
Updated•3 months ago
|
Comment 67•3 months ago
|
||
The patch landed in nightly and beta is affected.
:gerard-majax, is this bug important enough to require an uplift?
- If yes, please nominate the patch for beta approval.
- See https://wiki.mozilla.org/Release_Management/Requesting_an_Uplift for documentation on how to request an uplift.
- If no, please set
status-firefox153towontfix.
For more information, please visit BugBot documentation.
Updated•2 months ago
|
Updated•2 months ago
|
| Assignee | ||
Comment 68•2 months ago
|
||
This is dependant on gecko upstream fixes that would not get uplifted
Updated•2 months ago
|
Description
•