https://bugs.winehq.org/show_bug.cgi?id=47787
--- Comment #3 from Jeff Smith whydoubt@gmail.com --- As a workaround, map the "nearest" mount point to a drive letter.
In CPython, the resolve() method eventually calls os__getfinalpathname_impl in Modules/posixmodule.c. Prior to CPython 3.6.5, one of the calls made from there is GetFinalPathNameByHandle(...,0,0,VOLUME_NAME_NT).
If the path being checked is on a mounted drive NOT mapped to a drive letter in Wine configuration, the GetFinalPathNameByHandle call will fail. For instance, on my machine /home is a mount point. While / is mapped to Z:, /home is not mapped. If I try to check /home/jeff it will fail. Note that cross-volume symbolic links likely trigger this issue as well. Python 3.5 and 3.6 deal with the failure in different ways, but this is where the problem originates.
An actual fix for GetFinalPathNameByHandle does not appear to be a simple task, but I have submitted a patch to emit a fixme message when the situation is encountered. https://source.winehq.org/patches/data/170201