Skip to content

Commit

Permalink
Error notification fix (#83)
Browse files Browse the repository at this point in the history
* fix error check

* hide eta for finished runs

* eta only for working

* stash fixed

---------

Co-authored-by: oxyplay <max@oxyplay.com>
  • Loading branch information
mitya52 and oxyplay authored Aug 31, 2023
1 parent 79e152d commit faff63c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion self_hosting_machinery/webgui/static/tab-finetune.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ function render_runs() {
} else {
run_status.innerHTML = `<span class="badge rounded-pill ${status_color}">${element.status}</span>`;
}
if (element.eta_minutes) {
if (element.status === 'working' && element.eta_minutes ) {
run_minutes.innerHTML = element.eta_minutes;
}
run_steps.innerHTML = element.worked_steps;
Expand Down
4 changes: 2 additions & 2 deletions self_hosting_machinery/webgui/static/tab-model-hosting.js
Original file line number Diff line number Diff line change
Expand Up @@ -86,13 +86,13 @@ function get_models()
enable_chat_gpt_switch.checked = models_data['openai_api_enable'];
enable_chat_gpt_switch.addEventListener('change', save_model_assigned);
const more_gpus_notification = document.querySelector('.model-hosting-error');
if(models_data && models_data.length > 0 && models_data.more_models_than_gpus) {
if(data.hasOwnProperty('more_models_than_gpus') && data.more_models_than_gpus) {
more_gpus_notification.classList.remove('d-none');
} else {
more_gpus_notification.classList.add('d-none');
}
const required_memory_exceed_available = document.querySelector('.model-memory-error');
if(models_data && models_data.length > 0 && models_data.required_memory_exceed_available) {
if(data.hasOwnProperty('required_memory_exceed_available') && data.required_memory_exceed_available) {
required_memory_exceed_available.classList.remove('d-none');
} else {
required_memory_exceed_available.classList.add('d-none');
Expand Down

0 comments on commit faff63c

Please sign in to comment.