diff --git a/changelog/4248.trivial.rst b/changelog/4248.trivial.rst new file mode 100644 index 00000000000..ecd9399a7c6 --- /dev/null +++ b/changelog/4248.trivial.rst @@ -0,0 +1 @@ +Remove use of unnecessary compat shim, six.binary_type diff --git a/src/_pytest/pathlib.py b/src/_pytest/pathlib.py index ba9dcdfb312..7cf3f40b62d 100644 --- a/src/_pytest/pathlib.py +++ b/src/_pytest/pathlib.py @@ -159,7 +159,7 @@ def create_cleanup_lock(p): else: pid = os.getpid() spid = str(pid) - if not isinstance(spid, six.binary_type): + if not isinstance(spid, bytes): spid = spid.encode("ascii") os.write(fd, spid) os.close(fd)