diff --git a/setup/resources.py b/setup/resources.py index 058e24310b..6a0d122ee7 100644 --- a/setup/resources.py +++ b/setup/resources.py @@ -286,6 +286,8 @@ class RecentUAs(Command): def run(self, opts): lines = self.get_list()[:10] + if not lines: + raise RuntimeError('Failed to download list of common user agents') with open(self.UA_PATH, 'wb') as f: f.write('\n'.join(lines).encode('ascii'))