Using os.Path.pathType() on Windows
How to identify absolute file paths on Windows®, whether using a drive letter or not.
Before version 3.10, on Windows
platforms, a file name starting with a directory-separator (slash or backslash) was not interpreted
by os.Path.pathType()
as an absolute name. As result, such files where considered
as relative path and searched by concatenating the path to the elements defined in FGLLDPATH,
FGLRESOURCEPATH, FGLIMAGEPATH.
Starting with version 3.10, a file name starting with a directory-separator or starting with a drive letter, is considered an absolute file path.
This change has also an impact on the os.Path.join
method, which returns the second parameter only if it is identified as an absolute path.