from _typeshed import StrOrBytesPath

class Pidfile:
    fname: StrOrBytesPath
    pid: int | None

    def __init__(self, fname: StrOrBytesPath) -> None: ...
    def create(self, pid: int) -> None: ...
    def rename(self, path: StrOrBytesPath) -> None: ...
    def unlink(self) -> None: ...
    def validate(self) -> None: ...
