|
15 | 15 | LicensedItemCheckoutGet, |
16 | 16 | ) |
17 | 17 | from models_library.api_schemas_webserver.licensed_items import ( |
18 | | - LicensedItemRpcGet as _LicensedItemGet, |
19 | | -) |
20 | | -from models_library.api_schemas_webserver.licensed_items import ( |
21 | | - LicensedItemRpcGetPage as _LicensedItemGetPage, |
| 18 | + LicensedItemRpcGet, |
| 19 | + LicensedItemRpcGetPage, |
22 | 20 | ) |
23 | 21 | from models_library.api_schemas_webserver.licensed_items_checkouts import ( |
24 | 22 | LicensedItemCheckoutRpcGet, |
@@ -64,15 +62,15 @@ async def _get_backend_licensed_items( |
64 | 62 | product_name: str, |
65 | 63 | offset: int, |
66 | 64 | limit: int, |
67 | | -) -> _LicensedItemGetPage: |
| 65 | +) -> LicensedItemRpcGetPage: |
68 | 66 | if exception_to_raise is not None: |
69 | 67 | raise exception_to_raise |
70 | | - extra = _LicensedItemGet.model_config.get("json_schema_extra") |
| 68 | + extra = LicensedItemRpcGet.model_config.get("json_schema_extra") |
71 | 69 | assert isinstance(extra, dict) |
72 | 70 | examples = extra.get("examples") |
73 | 71 | assert isinstance(examples, list) |
74 | | - return _LicensedItemGetPage( |
75 | | - items=[_LicensedItemGet.model_validate(ex) for ex in examples], |
| 72 | + return LicensedItemRpcGetPage( |
| 73 | + items=[LicensedItemRpcGet.model_validate(ex) for ex in examples], |
76 | 74 | total=len(examples), |
77 | 75 | ) |
78 | 76 |
|
@@ -162,16 +160,16 @@ async def side_effect( |
162 | 160 | user_id: UserID, |
163 | 161 | offset: int, |
164 | 162 | limit: int, |
165 | | - ) -> _LicensedItemGetPage: |
| 163 | + ) -> LicensedItemRpcGetPage: |
166 | 164 | assert _wallet_id == wallet_id |
167 | 165 | if exception_to_raise is not None: |
168 | 166 | raise exception_to_raise |
169 | | - extra = _LicensedItemGet.model_config.get("json_schema_extra") |
| 167 | + extra = LicensedItemRpcGet.model_config.get("json_schema_extra") |
170 | 168 | assert isinstance(extra, dict) |
171 | 169 | examples = extra.get("examples") |
172 | 170 | assert isinstance(examples, list) |
173 | | - return _LicensedItemGetPage( |
174 | | - items=[_LicensedItemGet.model_validate(ex) for ex in examples], |
| 171 | + return LicensedItemRpcGetPage( |
| 172 | + items=[LicensedItemRpcGet.model_validate(ex) for ex in examples], |
175 | 173 | total=len(examples), |
176 | 174 | ) |
177 | 175 |
|
|
0 commit comments