Skip to content

Commit c945b49

Browse files
committed
fixup! [WIP] test zgw refactor
1 parent 75d3ae6 commit c945b49

File tree

1 file changed

+6
-12
lines changed

1 file changed

+6
-12
lines changed

src/open_inwoner/cms/cases/views/services.py

+6-12
Original file line numberDiff line numberDiff line change
@@ -125,15 +125,12 @@ def get_submissions(self) -> list[SubmissionWithApiGroup]:
125125
for task in concurrent.futures.as_completed(futures):
126126
try:
127127
group_for_task = all_api_groups[futures.index(task)]
128-
subs_with_api_group.extend(
129-
[
128+
for row in task.result():
129+
subs_with_api_group.append(
130130
SubmissionWithApiGroup(
131131
submission=row, api_group=group_for_task
132132
)
133-
for row in task.result()
134-
]
135-
)
136-
133+
)
137134
except BaseException:
138135
logger.exception("Error fetching and pre-processing cases")
139136

@@ -180,13 +177,10 @@ def get_cases(self) -> list[ZaakWithApiGroup]:
180177
):
181178
group_for_task = all_api_groups[futures.index(task)]
182179
try:
183-
cases_with_api_group.extend(
184-
[
180+
for row in task.result():
181+
cases_with_api_group.append(
185182
ZaakWithApiGroup(zaak=row, api_group=group_for_task)
186-
for row in task.result()
187-
]
188-
)
189-
183+
)
190184
except BaseException:
191185
logger.exception(
192186
"Error while fetching and pre-processing cases for API group %s",

0 commit comments

Comments
 (0)