Debugging one of the applications, I've noticed, that logs are never uploaded to the server and started to investigate why. Thing is, that someone wrote code like this:

public const string TimestampFormat = "MM/dd/yyyy HH:mm:ss"

This was used to produce file name and expect / to be in formatted date, then as long as it is not allowed symbol in file name, silently remove / symbol from time stamp string, then use wildcard to find files matching that string.

Things is, that .net framework handles "/" in date format this way:

case '/':
                    result.Append(dtfi.DateSeparator);
                    tokenLen = 1;
                    break;

and DateSeparator for various cultures might be different symbol (dot in case of Lithuanian regional settings), you would expect it not being overridden though, as you explicitly define format.

In this case it was best to enforce usage of Invariant culture in all places, where we expect date time format to be regional settings agnostic.

c#