You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
using wildcard search in MDF.search() with "case_insensitive=True" is not case-insensitive on Linux (while working fine in Windows).
This is caused by the fact, that the librariy "fnmatch" is used, which is designed to do file path comparisons. According to its documentation, it performs a "case normalization" (https://docs.python.org/3/library/fnmatch.html#fnmatch.fnmatch) but this does not mean "case-insensitive" as default Linux file systems are case-sensitive
if case_insensitive:
- channels = fnmatch.filter(self.channels_db, pattern)+ pattern = pattern.casefold()+ channels = [+ name+ for name in self.channels_db+ if fnmatch.fnmatch(name.casefold(), pattern)+ ]
else:
Possible workarounds:
use mode='regex'
use windows ;)
The text was updated successfully, but these errors were encountered:
Python version
Windows machine:
Linux machine:
Code
MDF version
Code snippet
Traceback
no traceback, as no Exception occurs
tracked down to following code:
asammdf/asammdf/mdf.py
Lines 5448 to 5450 in af0d4a6
Description
using wildcard search in MDF.search() with "case_insensitive=True" is not case-insensitive on Linux (while working fine in Windows).
This is caused by the fact, that the librariy "fnmatch" is used, which is designed to do file path comparisons. According to its documentation, it performs a "case normalization" (https://docs.python.org/3/library/fnmatch.html#fnmatch.fnmatch) but this does not mean "case-insensitive" as default Linux file systems are case-sensitive
The text was updated successfully, but these errors were encountered: