Skip to content

Commit

Permalink
Fix missing sys import in type_defs
Browse files Browse the repository at this point in the history
  • Loading branch information
vemel committed Oct 7, 2020
1 parent 2c523be commit 4c5d99a
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions mypy_boto3_builder/structures/service_package.py
Original file line number Diff line number Diff line change
Expand Up @@ -185,6 +185,7 @@ def get_type_defs_required_import_records(self) -> List[ImportRecord]:
return []

import_records: Set[ImportRecord] = set()
import_records.add(ImportRecord(ImportString("sys")))
import_records.add(
ImportRecord(
ImportString("typing"),
Expand All @@ -201,7 +202,5 @@ def get_type_defs_required_import_records(self) -> List[ImportRecord]:
if import_record.is_type_defs():
continue
import_records.add(import_record.get_external(self.service_name.module_name))
if import_record.fallback:
import_records.add(ImportRecord(ImportString("sys")))

return list(sorted(import_records))

0 comments on commit 4c5d99a

Please sign in to comment.