mirror of
https://github.com/ynput/ayon-core.git
synced 2026-01-01 08:24:53 +01:00
make sure path is string
This commit is contained in:
parent
4fa9cab65b
commit
93d0e28a63
1 changed files with 2 additions and 0 deletions
|
|
@ -225,6 +225,8 @@ def import_filepath(path: Path, module_name: Optional[str] = None):
|
|||
if not module_name:
|
||||
module_name = os.path.splitext(path.name)[0]
|
||||
|
||||
# Convert to string
|
||||
path = str(path)
|
||||
module = types.ModuleType(module_name)
|
||||
module.__file__ = path
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue