Skip to content

Commit

Permalink
[ML] call job validation endpoint with complete payload
Browse files Browse the repository at this point in the history
  • Loading branch information
darnautov committed Apr 2, 2020
1 parent a729b3b commit dd997c4
Show file tree
Hide file tree
Showing 2 changed files with 10 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -151,8 +151,15 @@ export const ml = {
});
},

validateJob({ job }: { job: Job }) {
const body = JSON.stringify({ job });
validateJob(payload: {
job: Job;
duration: {
start?: number;
end?: number;
};
fields?: any[];
}) {
const body = JSON.stringify(payload);
return http<any>({
path: `${basePath()}/validate/job`,
method: 'POST',
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ export async function validateModelMemoryLimit(

// if there is no duration, do not run the estimate test
const runCalcModelMemoryTest =
duration && typeof duration?.start !== undefined && duration?.end !== undefined;
duration && duration?.start !== undefined && duration?.end !== undefined;

// retrieve the max_model_memory_limit value from the server
// this will be unset unless the user has set this on their cluster
Expand Down

0 comments on commit dd997c4

Please sign in to comment.