diff --git a/depsBundle.py b/depsBundle.py index 128c4c7..892003c 100644 --- a/depsBundle.py +++ b/depsBundle.py @@ -21,10 +21,13 @@ def _get_project_dict() -> dict[str, Any]: subprocess.run(toml_install_pip_args, check=True) sys.path.insert(0, toml_env) import toml + mode = "r" else: import tomllib as toml - with open("pyproject.toml") as pyproject_toml: + mode = "rb" + + with open("pyproject.toml", mode) as pyproject_toml: return toml.load(pyproject_toml)