We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
__fspath__
Currently, gin is not compliant with PEP 519.
Modern Python file system operations uses pathlib-like API. Which is not supported by gin:
path = pathlib.Path('/path/to/c.gin') gin.parse_config_files_and_bindings(path) # Error
It is very easy to solve. Function should normalize pathlib-like object, like:
path = os.fspath(path) # Convert pathlib & cie -> str
To check whether an object is a pathlib object:
isinstance(path, (str, os.PathLike))
The text was updated successfully, but these errors were encountered:
My bad. It was my mistake in the previous example (parse_config_files_and_bindings([path]))
parse_config_files_and_bindings([path])
Sorry, something went wrong.
No branches or pull requests
Currently, gin is not compliant with PEP 519.
Modern Python file system operations uses pathlib-like API. Which is not supported by gin:
It is very easy to solve. Function should normalize pathlib-like object, like:
To check whether an object is a pathlib object:
The text was updated successfully, but these errors were encountered: