Python 3.4 (and above) has a module called pathlib which is for representing and working with paths. So, an instance of the pathlib class is an object which represents a path on the system (e.g. /home/my_file.py). I can use it to read a files contents, write to a file, etc... A file object is a, not surprisingly, an object which represents a file. I can use it to read a files contents, write to a file, etc...
So, what is the difference between the two objects? Why choose one over the other? Obviously, a file object isn't used to make copies or check the current working directory so there are reasons to choose pathlib when we need cerain behaviours. However, it seems pathlib does everything I might want a file object to do so why bother with file objects?