diff --git a/antarest/eventbus/web.py b/antarest/eventbus/web.py index cae0ffb99f..d7675b20ec 100644 --- a/antarest/eventbus/web.py +++ b/antarest/eventbus/web.py @@ -91,7 +91,7 @@ async def send_event_to_ws(event: Event) -> None: @application.websocket("/ws") async def connect( websocket: WebSocket, - token: str = Query(...), + token: str = Query(), jwt_manager: AuthJWT = Depends(), ) -> None: user: Optional[JWTUser] = None diff --git a/antarest/launcher/web.py b/antarest/launcher/web.py index a4a1c45ba6..4bb21db540 100644 --- a/antarest/launcher/web.py +++ b/antarest/launcher/web.py @@ -201,23 +201,7 @@ def get_load( response_model=List[str], ) def get_solver_versions( - solver: str = Query( - "default", - examples={ - "Default solver": { - "description": "Get the solver versions of the default configuration", - "value": "default", - }, - "SLURM solver": { - "description": "Get the solver versions of the SLURM server if available", - "value": "slurm", - }, - "Local solver": { - "description": "Get the solver versions of the Local server if available", - "value": "local", - }, - }, - ) + solver: str = Query("default", examples=["default", "slurm", "local"]), ) -> List[str]: """ Get list of supported solver versions defined in the configuration. diff --git a/antarest/study/web/study_data_blueprint.py b/antarest/study/web/study_data_blueprint.py index de9fbcecd1..69bf5ba62b 100644 --- a/antarest/study/web/study_data_blueprint.py +++ b/antarest/study/web/study_data_blueprint.py @@ -1017,23 +1017,7 @@ def set_allocation_form_fields( ) def get_correlation_matrix( uuid: str, - columns: Optional[str] = Query( - None, - examples={ - "all areas": { - "description": "get the correlation matrix for all areas (by default)", - "value": "", - }, - "single area": { - "description": "get the correlation column for a single area", - "value": "north", - }, - "selected areas": { - "description": "get the correlation columns for a selected list of areas", - "value": "north,east", - }, - }, - ), # type: ignore + columns: str = Query("", examples=["", "north", "north,east"]), current_user: JWTUser = Depends(auth.get_current_user), ) -> CorrelationMatrix: """ @@ -1058,11 +1042,8 @@ def get_correlation_matrix( study_service.get_all_areas(uuid, area_type=AreaType.AREA, ui=False, params=params), ) manager = CorrelationManager(study_service.storage_service) - return manager.get_correlation_matrix( - all_areas, - study, - columns.split(",") if columns else [], - ) + cols = columns.split(",") if columns else [] + return manager.get_correlation_matrix(all_areas, study, cols) @bp.put( path="/studies/{uuid}/areas/hydro/correlation/matrix",