aboutsummaryrefslogtreecommitdiffstats
path: root/python/fatcat_tools/cleanups
diff options
context:
space:
mode:
authorBryan Newbold <bnewbold@robocracy.org>2021-11-17 17:31:59 -0800
committerBryan Newbold <bnewbold@robocracy.org>2021-11-23 17:39:02 -0800
commitecbaa7ff48d046e77547a69dd2be8ef0c7b9bf04 (patch)
treea2caf61b6104d48d97febc685fe94cd82f00603c /python/fatcat_tools/cleanups
parent5dc4a695c8d7b802f58d26c78e4209d52c907693 (diff)
downloadfatcat-bnewbold-pythonclient-types.tar.gz
fatcat-bnewbold-pythonclient-types.zip
WIP: start fixing types and lints from openapi annotationsbnewbold-pythonclient-types
Diffstat (limited to 'python/fatcat_tools/cleanups')
-rw-r--r--python/fatcat_tools/cleanups/common.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/python/fatcat_tools/cleanups/common.py b/python/fatcat_tools/cleanups/common.py
index 1b467b59..aa26acaf 100644
--- a/python/fatcat_tools/cleanups/common.py
+++ b/python/fatcat_tools/cleanups/common.py
@@ -54,7 +54,7 @@ class EntityCleaner:
def reset(self) -> None:
self.counts = Counter({"lines": 0, "cleaned": 0, "updated": 0})
self._edit_count = 0
- self._editgroup_id = None
+ self._editgroup_id: Optional[str] = None
self._entity_queue: List[Any] = []
self._idents_inflight: List[str] = []
@@ -72,7 +72,7 @@ class EntityCleaner:
self.counts["skip-null"] += 1
return
- entity = entity_from_dict(record, self.entity_type, api_client=self.ac)
+ entity = entity_from_dict(record, self.entity_type, api_client=self.ac.api_client)
if entity.state != "active":
self.counts["skip-inactive"] += 1
@@ -86,7 +86,7 @@ class EntityCleaner:
self.counts["cleaned"] += 1
if self.dry_run_mode:
- entity_dict = entity_to_dict(entity, api_client=self.ac)
+ entity_dict = entity_to_dict(entity, api_client=self.ac.api_client)
print(json.dumps(entity_dict))
return