mlem
mlem copied to clipboard
Don't assume paths are strings
Some parts of the code assume paths to be strings e.g. https://github.com/iterative/mlem/blob/4666de893967cdde41bf5ff605acf51a84bc9b68/mlem/utils/path.py#L8
If you pass a pathlib's path, then you'd get the following error:
...
6 if not path:
7 return path
----> 8 return path.replace("\\", "/")
TypeError: replace() takes 2 positional arguments but 3 were given