I want to use a user-provided string as a filename for exporting, but have to make sure that the string is permissible on my system as a filename. From my side it would be OK to replace any forbidden character with e.g. '_'.
Here I found a list of forbidden characters for filenames.
It should be easy enough to use the str.replace()
function, I was just wondering if there is already something out there that does that, potentially even taking into account what OS I am on.