Skip to content

Commit b60215c

Browse files
committed
permalink factory: _crud_api_read.list_projects_full_depth depend on app
1 parent 636ee8a commit b60215c

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

services/web/server/src/simcore_service_webserver/projects/_crud_api_read.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -165,7 +165,7 @@ async def list_projects( # pylint: disable=too-many-arguments
165165

166166

167167
async def list_projects_full_depth(
168-
request,
168+
app: web.Application,
169169
*,
170170
user_id: UserID,
171171
product_name: str,
@@ -180,10 +180,10 @@ async def list_projects_full_depth(
180180
search_by_multi_columns: str | None,
181181
search_by_project_name: str | None,
182182
) -> tuple[list[ProjectDict], int]:
183-
db = ProjectDBAPI.get_from_app_context(request.app)
183+
db = ProjectDBAPI.get_from_app_context(app)
184184

185185
user_available_services: list[dict] = await get_services_for_user_in_product(
186-
request.app, user_id, product_name, only_key_versions=True
186+
app, user_id, product_name, only_key_versions=True
187187
)
188188

189189
db_projects, db_project_types, total_number_projects = await db.list_projects_dicts(
@@ -202,12 +202,12 @@ async def list_projects_full_depth(
202202
order_by=order_by,
203203
)
204204

205-
db_projects = await _batch_update_list_of_project_dict(request.app, db_projects)
205+
db_projects = await _batch_update_list_of_project_dict(app, db_projects)
206206

207207
projects: list[ProjectDict] = await logged_gather(
208208
*(
209209
_update_project_dict(
210-
request.app,
210+
app,
211211
user_id=user_id,
212212
project=prj,
213213
is_template=prj_type == ProjectTypeDB.TEMPLATE,

services/web/server/src/simcore_service_webserver/projects/_crud_handlers.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -252,7 +252,7 @@ async def list_projects_full_search(request: web.Request):
252252
tag_ids_list = query_params.tag_ids_list()
253253

254254
projects, total_number_of_projects = await _crud_api_read.list_projects_full_depth(
255-
request,
255+
request.app,
256256
user_id=req_ctx.user_id,
257257
product_name=req_ctx.product_name,
258258
trashed=query_params.filters.trashed,

services/web/server/src/simcore_service_webserver/projects/_trash_service.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,7 @@ async def list_trashed_projects(
139139
Lists all projects that were trashed until a specific datetime.
140140
"""
141141
projects, _ = await _crud_api_read.list_projects_full_depth(
142-
request=app,
142+
app,
143143
user_id=user_id,
144144
product_name=product_name,
145145
trashed=True,

0 commit comments

Comments
 (0)