diff --git a/src/poetry/core/packages/dependency.py b/src/poetry/core/packages/dependency.py index c01ede94f..a539d59b6 100644 --- a/src/poetry/core/packages/dependency.py +++ b/src/poetry/core/packages/dependency.py @@ -253,7 +253,7 @@ def base_pep_508_name(self) -> str: requirement = self.pretty_name if self.extras: - extras = ",".join(self.extras) + extras = ",".join(sorted(self.extras)) requirement += f"[{extras}]" if isinstance(self.constraint, VersionUnion):