Open
Description
This isn't a problem with python 3.11 (tested in a conda environment on the same machine). It appears in python 3.12 on windows. The error returned prevents paths from being built. The fix is simply to cast the authopath object to a string first. Maybe it's not an issue with autopaths.
import pathlib
from autopaths.dir_path import DirectoryPath
p_autopaths = DirectoryPath("~")
# This is generating an error on Windows with python 3.12
p1 = pathlib.Path(p_autopaths)
print(p1 / "test")
# This is not generating the error
p2 = pathlib.Path(str(p_autopaths))
print(p2 / "test")
Related to https://gitlab.com/bioeconomy/eu_cbm/eu_cbm_hat/-/issues/85
Metadata
Metadata
Assignees
Labels
No labels