diff --git a/poetry_multiproject_plugin/commands/buildproject/project.py b/poetry_multiproject_plugin/commands/buildproject/project.py index 86f59ec..b7018e2 100644 --- a/poetry_multiproject_plugin/commands/buildproject/project.py +++ b/poetry_multiproject_plugin/commands/buildproject/project.py @@ -79,7 +79,12 @@ def rewrite_modules(self, project_path: Path, top_ns: str) -> None: def prepare_for_build(self, path: Path): project_poetry = Factory().create_poetry(path) - self.set_poetry(project_poetry) + if hasattr(self, "set_poetry"): + self.set_poetry(project_poetry) + elif hasattr(self, "_poetry"): + self._poetry = project_poetry + else: + raise ValueError("Cannot find expected Poetry Command internals.") def handle(self): path = self.poetry.file.path.absolute() diff --git a/pyproject.toml b/pyproject.toml index dc6589d..898a2ae 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [tool.poetry] name = "poetry-multiproject-plugin" -version = "1.8.1" +version = "1.8.2" description = "A Poetry plugin that makes it possible to use relative package includes." authors = ["David Vujic"] license = "MIT"