diff --git a/setup.py b/setup.py index 6f6da7156c3..277965837c3 100644 --- a/setup.py +++ b/setup.py @@ -252,9 +252,7 @@ def build_extensions(self): build_ext.build_extensions(self) - longest = 0 - if self.extensions: - longest = max([len(e.name) for e in self.extensions]) + longest = max([len(e.name) for e in self.extensions], default=0) if self.failed: longest = max(longest, max([len(name) for name in self.failed]))