Mar-23-2018, 08:35 AM
Python 3.6.3 | Ubuntu 17.10
If you're able to install build tools on your system, you can use pyenv.
One another option could be, that you try to install this: https://pypi.python.org/pypi/pathlib2/
Or you make your own helpers for the method resolve.
In [4]: pathlib.Path('../dev/foo/baz/../baz/andre').resolve() Out[4]: PosixPath('/home/dev/foo/baz/andre')Python 3.5.3 | Debian 9.3
pathlib.Path('../dev/foo/baz/../baz/andre').resolve()
Error:FileNotFoundError: [Errno 2] No such file or directory: '/dev/foo'
The answer why this happens, is here: https://docs.python.org/3/library/pathli...th.resolveQuote:If the path doesn’t exist and strict is True, FileNotFoundError is raised. If strict is False, the path is resolved as far as possible and any remainder is appended without checking whether it exists. If an infinite loop is encountered along the resolution path, RuntimeError is raised.
New in version 3.6: The strict argument.
If you're able to install build tools on your system, you can use pyenv.
One another option could be, that you try to install this: https://pypi.python.org/pypi/pathlib2/
Or you make your own helpers for the method resolve.
Almost dead, but too lazy to die: https://sourceserver.info
All humans together. We don't need politicians!
All humans together. We don't need politicians!