mirror of
https://github.com/wassname/optuna-dashboard.git
synced 2026-10-04 12:50:44 +08:00
fix by review
This commit is contained in:
1 parent
32a4f2d4e1
commit
88e3d511d5
2 files changed
+3
-2
No files matched your search
@@ -312,7 +312,7 @@ def create_app(
|
||||
|
||||
@app.put("/api/studies/<study_id:int>/preference_feedback_component_type")
|
||||
@json_api_view
|
||||
def put_component(study_id: int) -> dict[str, Any]:
|
||||
def put_preference_feedback_component_type(study_id: int) -> dict[str, Any]:
|
||||
try:
|
||||
component_type = request.json.get("type", "")
|
||||
artifact_key = request.json.get("artifact_key", None)
|
||||
@@ -329,6 +329,8 @@ def create_app(
|
||||
component_type=component_type,
|
||||
artifact_key=artifact_key,
|
||||
)
|
||||
response.status = 204
|
||||
return {}
|
||||
|
||||
@app.delete("/api/studies/<study_id:int>/preference/<history_id>")
|
||||
@json_api_view
|
||||
|
||||
@@ -168,7 +168,6 @@ def serialize_study_detail(
|
||||
serialized["feedback_component_type"] = system_attrs.get(
|
||||
_SYSTEM_ATTR_FEEDBACK_COMPONENT, {}
|
||||
)
|
||||
if serialized["is_preferential"]:
|
||||
serialized["preference_history"] = serialize_preference_history(system_attrs)
|
||||
serialized["preferences"] = get_preferences(system_attrs)
|
||||
serialized["plotly_graph_objects"] = [
|
||||
|
||||
Reference in new issue
Block a user