mirror of
https://github.com/wassname/optuna-dashboard.git
synced 2026-09-23 13:30:25 +08:00
Apply suggestions from code review
Co-authored-by: Hiroyuki Vincent Yamazaki <hiroyuki.vincent.yamazaki@gmail.com>
This commit is contained in:
co-authored by
Hiroyuki Vincent Yamazaki
parent
887ed02fdf
commit
c822e3450c
@@ -436,7 +436,7 @@ def create_app(storage: BaseStorage, debug: bool = False) -> Bottle:
|
||||
values = [float(v) for v in vs]
|
||||
except (ValueError, TypeError):
|
||||
response.status = 400 # Bad request
|
||||
return {"reason": "values attribute must be number's array"}
|
||||
return {"reason": "values attribute must be an array of numbers"}
|
||||
|
||||
try:
|
||||
storage.set_trial_state_values(trial_id, state, values)
|
||||
|
||||
@@ -50,7 +50,7 @@ export const actionCreator = () => {
|
||||
setStudyDetailState(studyId, newStudy)
|
||||
}
|
||||
|
||||
const setTrialState = (
|
||||
const setTrialStateValues = (
|
||||
studyId: number,
|
||||
index: number,
|
||||
state: TrialState,
|
||||
@@ -307,7 +307,7 @@ export const actionCreator = () => {
|
||||
return
|
||||
}
|
||||
setTrialState(studyId, index, state, values)
|
||||
enqueueSnackbar(`Success to update trial (${message})`, {
|
||||
enqueueSnackbar(`Successfully updated trial (${message})`, {
|
||||
variant: "success",
|
||||
})
|
||||
})
|
||||
|
||||
@@ -341,7 +341,7 @@ export const TrialTable: FC<{
|
||||
<Grid item xs={12}>
|
||||
<Box margin={1}>
|
||||
<Typography variant="h6" gutterBottom component="div">
|
||||
Trial tell operations
|
||||
Trial tell
|
||||
</Typography>
|
||||
<form onSubmit={handleSubmit}>
|
||||
<Box margin={1}>
|
||||
|
||||
Reference in New Issue
Block a user