A number of tests use pathlib.Path to test that the code supports path-like objects. They should use a special object that only implements the path protocol instead. This will avoid unintentional dependency on other pathlib.Path methods and attributes and allow to test path-like objects with the bytes path.
Linked PRs