Fair enough regarding the Windows callout. The MacOS callout, however, does show specifically setting the “Date format”.
This page describesLANG and LC_TIME relate to each other on POSIX systems.
I can see the in the discussion you linked, that @am4c130d, @iomys, and @argentum have also mentioned this issue. However, since the feature request, at least per it’s title, is asking for the option to change the date & time format within Obsidian, independently of the OS, I believe this topic should be continued here.
I did some digging, and it seems that the cause of this issue traces back through Electron and NodeJS into V8.
- Here someone noticed, that NodeJS uses the
LANG locale instead of the LC_TIME as the default locale for date formatting with toLocaleString().
- On MDN it is mentioned that the
toLocaleString() function is often implemented as depending on the Intl namespace, which in my own testing also uses the wrong locale.
- In this StackExchange question, the OP noticed this issue in their browser. The reply mentions there are bug reports for this behavior for both, Firefox and Chrome. Indeed, the Firefox bug report is still open at the time of writing this.
I can see that the issue arguably is caused upstream of Obsidian, and also that it only affects few users, namely those who use Linux and have at some point changed their OS’s default date & time format.
However, it stands that Obsidian’s intended behavior according to it’s help pages, i.e. to follow the OS’s default date & time format, differs from it’s actual behavior. Thus, this constitutes a Bug.
Without knowing the code in detail, it seems to me, it could be fixed by reading the process.env.LC_TIME environment variable and, if it is set, providing it to the relevant invocations of toLocaleString(), or whatever function is used to turn dates to strings.
It may seem a bit presumptions of me to give suggestions on how to implement a fix, I hope you’ll forgive me that transgression. My only aim is to illustrate that a fix does seem possible.
To be honest, I am a bit surprised by the responses so far. Or perhaps I am mistaken, and this is not the place to report bugs? That said, it remains entirely your choice whether to address the issue or leave it be. As such, I don’t think I will press this any further and may not invest more time into this.
Kind Regards