zrb 1.0.0a18__py3-none-any.whl → 1.0.0a19__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- zrb/__init__.py +2 -0
- zrb/input/any_input.py +4 -0
- zrb/input/base_input.py +4 -4
- zrb/input/bool_input.py +1 -1
- zrb/input/float_input.py +2 -2
- zrb/input/int_input.py +1 -1
- zrb/input/option_input.py +2 -2
- zrb/input/password_input.py +2 -2
- zrb/input/text_input.py +2 -2
- zrb/runner/cli.py +2 -30
- zrb/runner/common_util.py +31 -0
- zrb/runner/web_app.py +20 -4
- zrb/runner/web_controller/static/pico.min.css +1 -1
- zrb/runner/web_controller/static/task-ui/common-util.js +63 -0
- zrb/runner/web_controller/static/task-ui/current-session.js +164 -0
- zrb/runner/web_controller/static/task-ui/event.js +120 -0
- zrb/runner/web_controller/static/task-ui/past-session.js +138 -0
- zrb/runner/web_controller/task_ui/controller.py +20 -19
- zrb/runner/web_controller/task_ui/view.html +12 -15
- {zrb-1.0.0a18.dist-info → zrb-1.0.0a19.dist-info}/METADATA +1 -1
- {zrb-1.0.0a18.dist-info → zrb-1.0.0a19.dist-info}/RECORD +23 -22
- zrb/runner/web_controller/task_ui/partial/common-util.js +0 -37
- zrb/runner/web_controller/task_ui/partial/main.js +0 -195
- zrb/runner/web_controller/task_ui/partial/show-existing-session.js +0 -97
- zrb/runner/web_controller/task_ui/partial/visualize-history.js +0 -104
- {zrb-1.0.0a18.dist-info → zrb-1.0.0a19.dist-info}/WHEEL +0 -0
- {zrb-1.0.0a18.dist-info → zrb-1.0.0a19.dist-info}/entry_points.txt +0 -0
@@ -0,0 +1,120 @@
|
|
1
|
+
window.addEventListener("load", async function () {
|
2
|
+
// Get current session
|
3
|
+
if (cfg.SESSION_NAME != "") {
|
4
|
+
CURRENT_SESSION.pollCurrentSession();
|
5
|
+
}
|
6
|
+
// set maxStartDate to today
|
7
|
+
const tomorrow = new Date();
|
8
|
+
tomorrow.setDate(tomorrow.getDate() + 1); // Move to the next day
|
9
|
+
tomorrow.setHours(0, 0, 0, 0);
|
10
|
+
const formattedTomorrow = UTIL.toLocalDateInputValue(tomorrow);
|
11
|
+
const maxStartAtInput = document.getElementById("max-start-at-input");
|
12
|
+
maxStartAtInput.value = formattedTomorrow;
|
13
|
+
// set minStartDate to yesterday
|
14
|
+
const today = new Date();
|
15
|
+
today.setHours(0, 0, 0, 0); // Set time to 00:00:00
|
16
|
+
const formattedToday = UTIL.toLocalDateInputValue(today);
|
17
|
+
const minStartAtInput = document.getElementById("min-start-at-input");
|
18
|
+
minStartAtInput.value = formattedToday;
|
19
|
+
// Update session
|
20
|
+
PAST_SESSION.pollPastSession();
|
21
|
+
});
|
22
|
+
|
23
|
+
|
24
|
+
const submitTaskForm = document.getElementById("submit-task-form");
|
25
|
+
submitTaskForm.addEventListener("input", async function(event) {
|
26
|
+
const currentInput = event.target;
|
27
|
+
const inputs = Array.from(submitTaskForm.querySelectorAll("input[name]"));
|
28
|
+
const inputMap = {};
|
29
|
+
const fixedInputNames = [];
|
30
|
+
for (const input of inputs) {
|
31
|
+
fixedInputNames.push(input.name);
|
32
|
+
if (input === currentInput) {
|
33
|
+
inputMap[input.name] = currentInput.value;
|
34
|
+
break;
|
35
|
+
} else {
|
36
|
+
inputMap[input.name] = input.value;
|
37
|
+
}
|
38
|
+
}
|
39
|
+
const queryString = new URLSearchParams(
|
40
|
+
{query: JSON.stringify(inputMap)}
|
41
|
+
).toString();
|
42
|
+
try {
|
43
|
+
// Send the AJAX request
|
44
|
+
const response = await fetch(`${cfg.INPUT_API_URL}?${queryString}`, {
|
45
|
+
method: "GET",
|
46
|
+
headers: {
|
47
|
+
"Content-Type": "application/json"
|
48
|
+
},
|
49
|
+
});
|
50
|
+
if (response.ok) {
|
51
|
+
const data = await response.json();
|
52
|
+
// Update the values of all subsequent inputs based on the response
|
53
|
+
Object.entries(data).forEach(([key, value]) => {
|
54
|
+
if (fixedInputNames.includes(key)) {
|
55
|
+
return;
|
56
|
+
}
|
57
|
+
const input = submitTaskForm.querySelector(`[name="${key}"]`);
|
58
|
+
input.value = value;
|
59
|
+
});
|
60
|
+
} else {
|
61
|
+
console.error("Failed to fetch updated values:", response.statusText);
|
62
|
+
}
|
63
|
+
} catch (error) {
|
64
|
+
console.error("Error during fetch:", error);
|
65
|
+
}
|
66
|
+
})
|
67
|
+
|
68
|
+
|
69
|
+
function openPastSessionDialog(event) {
|
70
|
+
event.preventDefault();
|
71
|
+
const dialog = document.getElementById("past-session-dialog")
|
72
|
+
dialog.showModal();
|
73
|
+
}
|
74
|
+
|
75
|
+
|
76
|
+
function closePastSessionDialog(event) {
|
77
|
+
event.preventDefault();
|
78
|
+
const dialog = document.getElementById("past-session-dialog")
|
79
|
+
dialog.close();
|
80
|
+
}
|
81
|
+
|
82
|
+
|
83
|
+
async function submitNewSessionForm(event) {
|
84
|
+
// Prevent the form from submitting the traditional way
|
85
|
+
event.preventDefault();
|
86
|
+
// Select the form
|
87
|
+
const form = document.getElementById("submit-task-form");
|
88
|
+
// Initialize an empty object to hold form data
|
89
|
+
const formData = {};
|
90
|
+
// Iterate through each input in the form
|
91
|
+
Array.from(form.elements).forEach(element => {
|
92
|
+
// Only include inputs with a name attribute and ignore buttons
|
93
|
+
if (element.name && (element.type !== "button" && element.type !== "submit")) {
|
94
|
+
formData[element.name] = element.value;
|
95
|
+
}
|
96
|
+
});
|
97
|
+
// Convert formData to JSON
|
98
|
+
const jsonData = JSON.stringify(formData);
|
99
|
+
try {
|
100
|
+
// Send the AJAX request
|
101
|
+
const response = await fetch(cfg.SESSION_API_URL, {
|
102
|
+
method: "POST",
|
103
|
+
headers: {
|
104
|
+
"Content-Type": "application/json"
|
105
|
+
},
|
106
|
+
body: jsonData
|
107
|
+
});
|
108
|
+
if (response.ok) {
|
109
|
+
const data = await response.json();
|
110
|
+
cfg.SESSION_NAME = data.session_name;
|
111
|
+
history.pushState(null, "", `${cfg.CURRENT_URL}${cfg.SESSION_NAME}`);
|
112
|
+
await PAST_SESSION.getAndRenderPastSession(0);
|
113
|
+
await CURRENT_SESSION.pollCurrentSession();
|
114
|
+
} else {
|
115
|
+
console.error("Error:", response);
|
116
|
+
}
|
117
|
+
} catch (error) {
|
118
|
+
console.error("Error:", error);
|
119
|
+
}
|
120
|
+
}
|
@@ -0,0 +1,138 @@
|
|
1
|
+
const PAST_SESSION = {
|
2
|
+
|
3
|
+
async pollPastSession() {
|
4
|
+
while (true) {
|
5
|
+
await this.getAndRenderPastSession(cfg.PAGE);
|
6
|
+
await UTIL.delay(5000);
|
7
|
+
}
|
8
|
+
},
|
9
|
+
|
10
|
+
async getAndRenderPastSession(page) {
|
11
|
+
cfg.PAGE=page
|
12
|
+
const minStartAtInput = document.getElementById("min-start-at-input");
|
13
|
+
const minStartAt = UTIL.formatDate(minStartAtInput.value);
|
14
|
+
const maxStartAtInput = document.getElementById("max-start-at-input");
|
15
|
+
const maxStartAt = UTIL.formatDate(maxStartAtInput.value);
|
16
|
+
const queryString = new URLSearchParams({
|
17
|
+
page: page,
|
18
|
+
from: minStartAt,
|
19
|
+
to: maxStartAt,
|
20
|
+
}).toString();
|
21
|
+
try {
|
22
|
+
// Send the AJAX request
|
23
|
+
const response = await fetch(`${cfg.SESSION_API_URL}list?${queryString}`, {
|
24
|
+
method: "GET",
|
25
|
+
headers: {
|
26
|
+
"Content-Type": "application/json"
|
27
|
+
},
|
28
|
+
});
|
29
|
+
if (response.ok) {
|
30
|
+
const {total, data} = await response.json();
|
31
|
+
this.showPastSession(page, total, data);
|
32
|
+
} else {
|
33
|
+
console.error("Error:", response);
|
34
|
+
}
|
35
|
+
} catch (error) {
|
36
|
+
console.error("Error:", error);
|
37
|
+
}
|
38
|
+
},
|
39
|
+
|
40
|
+
showPastSession(page, total, data) {
|
41
|
+
const ul = document.getElementById("past-session-ul");
|
42
|
+
ul.innerHTML = ''; // Clear existing content
|
43
|
+
data.forEach(item => {
|
44
|
+
const taskStatus = item.task_status[item.main_task_name];
|
45
|
+
const finalStatus = UTIL.getFinalTaskStatus(taskStatus);
|
46
|
+
const finalColor = UTIL.getFinalColor(finalStatus);
|
47
|
+
const taskHistories = taskStatus.history;
|
48
|
+
const taskStartTime = taskHistories.length > 0 ? taskHistories[0].time : ""
|
49
|
+
const li = document.createElement('li');
|
50
|
+
const a = document.createElement('a');
|
51
|
+
const dateSpan = document.createElement('span');
|
52
|
+
const statusSpan = document.createElement('span');
|
53
|
+
a.textContent = item.name;
|
54
|
+
a.target = '_blank';
|
55
|
+
a.href = `${cfg.UI_URL}${item.name}`;
|
56
|
+
li.appendChild(a);
|
57
|
+
statusSpan.style.marginLeft = "10px";
|
58
|
+
statusSpan.style.display = 'inline-block';
|
59
|
+
statusSpan.style.width = '15px';
|
60
|
+
statusSpan.style.height = '15px';
|
61
|
+
statusSpan.style.borderRadius = '50%';
|
62
|
+
statusSpan.style.border = '2px solid black';
|
63
|
+
statusSpan.style.backgroundColor = finalColor;
|
64
|
+
li.appendChild(statusSpan);
|
65
|
+
dateSpan.style.marginLeft = "10px";
|
66
|
+
dateSpan.textContent = taskStartTime;
|
67
|
+
li.appendChild(dateSpan);
|
68
|
+
ul.appendChild(li);
|
69
|
+
});
|
70
|
+
const paginationUl = document.getElementById("past-session-pagination-ul");
|
71
|
+
paginationUl.innerHTML = ''; // Clear previous pagination
|
72
|
+
|
73
|
+
const totalPages = Math.ceil(total / 10); // Calculate total pages based on page size
|
74
|
+
const maxPagesToShow = 5; // Number of pages to display around the current page
|
75
|
+
const halfMaxPages = Math.floor(maxPagesToShow / 2);
|
76
|
+
|
77
|
+
// Add first page and previous controls
|
78
|
+
if (page > 0) {
|
79
|
+
paginationUl.appendChild(this.createPageLink("⟪", 0)); // Go to first page
|
80
|
+
paginationUl.appendChild(this.createPageLink("⟨", page - 1)); // Go to previous page
|
81
|
+
}
|
82
|
+
|
83
|
+
let startPage = Math.max(0, page - halfMaxPages);
|
84
|
+
let endPage = Math.min(totalPages - 1, page + halfMaxPages);
|
85
|
+
|
86
|
+
if (page <= halfMaxPages) {
|
87
|
+
endPage = Math.min(totalPages - 1, maxPagesToShow - 1);
|
88
|
+
} else if (page + halfMaxPages >= totalPages) {
|
89
|
+
startPage = Math.max(0, totalPages - maxPagesToShow);
|
90
|
+
}
|
91
|
+
|
92
|
+
if (startPage > 1) {
|
93
|
+
paginationUl.appendChild(this.createEllipsis());
|
94
|
+
}
|
95
|
+
|
96
|
+
// Add page links within the calculated range
|
97
|
+
for (let i = startPage; i <= endPage; i++) {
|
98
|
+
if (i === page) {
|
99
|
+
const pageLi = document.createElement('li');
|
100
|
+
pageLi.textContent = i + 1;
|
101
|
+
paginationUl.append(pageLi)
|
102
|
+
} else {
|
103
|
+
paginationUl.appendChild(this.createPageLink(i + 1, i))
|
104
|
+
}
|
105
|
+
}
|
106
|
+
|
107
|
+
// Add ellipsis after the end page if needed
|
108
|
+
if (endPage < totalPages - 2) {
|
109
|
+
paginationUl.appendChild(this.createEllipsis());
|
110
|
+
}
|
111
|
+
|
112
|
+
// Add next and last page controls
|
113
|
+
if (page < totalPages - 1) {
|
114
|
+
paginationUl.appendChild(this.createPageLink("⟩", page + 1)); // Go to next page
|
115
|
+
paginationUl.appendChild(this.createPageLink("⟫", totalPages - 1)); // Go to last page
|
116
|
+
}
|
117
|
+
},
|
118
|
+
|
119
|
+
createPageLink(text, page) {
|
120
|
+
const li = document.createElement('li');
|
121
|
+
const link = document.createElement('a');
|
122
|
+
link.textContent = text;
|
123
|
+
link.href = '#';
|
124
|
+
link.onclick = (e) => {
|
125
|
+
e.preventDefault();
|
126
|
+
this.getAndRenderPastSession(page);
|
127
|
+
};
|
128
|
+
li.appendChild(link);
|
129
|
+
return li;
|
130
|
+
},
|
131
|
+
|
132
|
+
createEllipsis() {
|
133
|
+
const li = document.createElement('li');
|
134
|
+
li.textContent = '...';
|
135
|
+
return li;
|
136
|
+
},
|
137
|
+
|
138
|
+
}
|
@@ -1,3 +1,4 @@
|
|
1
|
+
import json
|
1
2
|
import os
|
2
3
|
|
3
4
|
from zrb.group.any_group import AnyGroup
|
@@ -10,14 +11,6 @@ _DIR = os.path.dirname(__file__)
|
|
10
11
|
|
11
12
|
_VIEW_TEMPLATE = read_file(os.path.join(_DIR, "view.html"))
|
12
13
|
_TASK_INPUT_TEMPLATE = read_file(os.path.join(_DIR, "partial", "input.html"))
|
13
|
-
_MAIN_SCRIPT = read_file(os.path.join(_DIR, "partial", "main.js"))
|
14
|
-
_SHOW_EXISTING_SESSION_SCRIPT = read_file(
|
15
|
-
os.path.join(_DIR, "partial", "show-existing-session.js")
|
16
|
-
)
|
17
|
-
_VISUALIZE_HISTORY_SCRIPT = read_file(
|
18
|
-
os.path.join(_DIR, "partial", "visualize-history.js")
|
19
|
-
)
|
20
|
-
_COMMON_UTIL_SCRIPT = read_file(os.path.join(_DIR, "partial", "common-util.js"))
|
21
14
|
|
22
15
|
|
23
16
|
def handle_task_ui(
|
@@ -31,12 +24,16 @@ def handle_task_ui(
|
|
31
24
|
# Assemble parent url
|
32
25
|
parent_url_parts = url_parts[:-2] + [""]
|
33
26
|
parent_url = "/".join(parent_url_parts)
|
34
|
-
# Assemble api url
|
35
|
-
|
36
|
-
|
37
|
-
|
27
|
+
# Assemble session api url
|
28
|
+
session_url_parts = list(url_parts)
|
29
|
+
session_url_parts[1] = "api/sessions"
|
30
|
+
session_api_url = "/".join(session_url_parts)
|
31
|
+
# Assemble input api url
|
32
|
+
input_url_parts = list(url_parts)
|
33
|
+
input_url_parts[1] = "api/inputs"
|
34
|
+
input_api_url = "/".join(input_url_parts)
|
38
35
|
# Assemble ui url
|
39
|
-
ui_url_parts = list(
|
36
|
+
ui_url_parts = list(url_parts)
|
40
37
|
ui_url_parts[1] = "ui"
|
41
38
|
ui_url = "/".join(ui_url_parts)
|
42
39
|
# Assemble task inputs
|
@@ -58,13 +55,17 @@ def handle_task_ui(
|
|
58
55
|
"url": url,
|
59
56
|
"parent_url": parent_url,
|
60
57
|
"task_inputs": "\n".join(input_html_list),
|
61
|
-
"api_url": api_url,
|
62
58
|
"ui_url": ui_url,
|
63
|
-
"
|
64
|
-
|
65
|
-
|
66
|
-
|
67
|
-
|
59
|
+
"json_cfg": json.dumps(
|
60
|
+
{
|
61
|
+
"CURRENT_URL": url,
|
62
|
+
"SESSION_API_URL": session_api_url,
|
63
|
+
"INPUT_API_URL": input_api_url,
|
64
|
+
"UI_URL": ui_url,
|
65
|
+
"SESSION_NAME": session_name,
|
66
|
+
"PAGE": 0,
|
67
|
+
}
|
68
|
+
),
|
68
69
|
},
|
69
70
|
)
|
70
71
|
)
|
@@ -19,16 +19,16 @@
|
|
19
19
|
<li><a href="/">🏠 Home</a></li>
|
20
20
|
<li><a href="{parent_url}">🔙 Parent</a></li>
|
21
21
|
<li><a href="{ui_url}">🆕 New Session</a></li>
|
22
|
-
<li><a href="#" onclick="
|
22
|
+
<li><a href="#" onclick="openPastSessionDialog(event)">📂 Existing Session</a></li>
|
23
23
|
</ul>
|
24
24
|
</nav>
|
25
25
|
</hgroup>
|
26
26
|
</header>
|
27
27
|
|
28
|
-
<dialog id="session-
|
28
|
+
<dialog id="past-session-dialog">
|
29
29
|
<article>
|
30
30
|
<header>
|
31
|
-
<button aria-label="Close" rel="prev" onclick="
|
31
|
+
<button aria-label="Close" rel="prev" onclick="closePastSessionDialog(event)"></button>
|
32
32
|
<p>
|
33
33
|
<strong>📂 Existing Session</strong>
|
34
34
|
</p>
|
@@ -40,11 +40,11 @@
|
|
40
40
|
<input type="datetime-local" id="max-start-at-input" placeholder="Maximum Start Time" aria-label="Maximum Start Time" />
|
41
41
|
</fieldset>
|
42
42
|
</form>
|
43
|
-
<ul id="session-
|
43
|
+
<ul id="past-session-ul" style="font-family:monospace;"></ul>
|
44
44
|
</main>
|
45
45
|
<footer>
|
46
46
|
<nav>
|
47
|
-
<ul id="session-
|
47
|
+
<ul id="past-session-pagination-ul"></ul>
|
48
48
|
</nav>
|
49
49
|
</footer>
|
50
50
|
</article>
|
@@ -55,7 +55,7 @@
|
|
55
55
|
<p>{description}</p>
|
56
56
|
<canvas id="history-canvas" height="0" width="1000" style="width: 100%;"></canvas>
|
57
57
|
<hr />
|
58
|
-
<form id="submit-task-form" onsubmit="
|
58
|
+
<form id="submit-task-form" onsubmit="submitNewSessionForm(event)">
|
59
59
|
{task_inputs}
|
60
60
|
<button>🚀 Run</button>
|
61
61
|
</form>
|
@@ -74,14 +74,11 @@
|
|
74
74
|
|
75
75
|
</body>
|
76
76
|
<script>
|
77
|
-
const
|
78
|
-
const API_URL = '{api_url}';
|
79
|
-
const UI_URL = `{ui_url}`;
|
80
|
-
let SESSION_NAME = '{session_name}';
|
81
|
-
let PAGE = 0;
|
82
|
-
{main_script}
|
83
|
-
{common_util_script}
|
84
|
-
{show_existing_session_script}
|
85
|
-
{visualize_history_script}
|
77
|
+
const cfg = {json_cfg};
|
86
78
|
</script>
|
79
|
+
<script src="/static/task-ui/common-util.js"></script>
|
80
|
+
<script src="/static/task-ui/past-session.js"></script>
|
81
|
+
<script src="/static/task-ui/current-session.js"></script>
|
82
|
+
<script src="/static/task-ui/event.js"></script>
|
83
|
+
|
87
84
|
</html>
|
@@ -1,4 +1,4 @@
|
|
1
|
-
zrb/__init__.py,sha256=
|
1
|
+
zrb/__init__.py,sha256=nH7AEA77p1Nipr3f8RVX6C9ltbq1W4DAjGjRW9s06lw,2830
|
2
2
|
zrb/__main__.py,sha256=tCRJm0qtx646ojZP8Rtgu8t_SDdSpply21HbR5poVvk,744
|
3
3
|
zrb/attr/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
4
4
|
zrb/attr/type.py,sha256=4TV5gPYMMrKh5V-yB6iRYKCbsXAH_AvGXMsjxKLHcUs,568
|
@@ -140,18 +140,19 @@ zrb/group/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
140
140
|
zrb/group/any_group.py,sha256=1rNcsi5eu_86JAx_6Jy46SK4BTeppcb89MORynJd-4o,1115
|
141
141
|
zrb/group/group.py,sha256=JFmWVEQ9PVy2WCf5pUG74iwL2xcGxXaAjT-NArAeloM,1861
|
142
142
|
zrb/input/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
143
|
-
zrb/input/any_input.py,sha256=
|
144
|
-
zrb/input/base_input.py,sha256=
|
145
|
-
zrb/input/bool_input.py,sha256=
|
146
|
-
zrb/input/float_input.py,sha256=
|
147
|
-
zrb/input/int_input.py,sha256=
|
148
|
-
zrb/input/option_input.py,sha256=
|
149
|
-
zrb/input/password_input.py,sha256=
|
143
|
+
zrb/input/any_input.py,sha256=0YxEaXvWyG3mWmBgUf3Z0HqtFag-JSoFuBSnfdqvWWI,803
|
144
|
+
zrb/input/base_input.py,sha256=AiSCxxYqJd5rlYsuzO1zqXQQ_ZuJsSONvR7t_m9Kj-I,3161
|
145
|
+
zrb/input/bool_input.py,sha256=zI1fea1k--r57vX61YVRog9sL_O7XX3gS7J3MGE8654,1383
|
146
|
+
zrb/input/float_input.py,sha256=W_FGgnL26l6iaNkWGHDXeu20B9QHAlyHonOVR2evin0,1015
|
147
|
+
zrb/input/int_input.py,sha256=tOgjhR8KYyahcmEto05lLzYtBowBUckwpcX4v-5sJlM,1005
|
148
|
+
zrb/input/option_input.py,sha256=S9IjGNzjPBexMb6BEuyyrPOcb10xjkFwVH02k2v7C2A,1939
|
149
|
+
zrb/input/password_input.py,sha256=C2alr0hgO_YLWf9MDF2H8w0NIIf_DZlDJSdKQwEyM0E,1311
|
150
150
|
zrb/input/str_input.py,sha256=NevZHX9rf1g8eMatPyy-kUX3DglrVAQpzvVpKAzf7bA,81
|
151
|
-
zrb/input/text_input.py,sha256=
|
151
|
+
zrb/input/text_input.py,sha256=7i0lvWYw79ILp0NEOBn-Twwnv7sBEgxJsqVaai6LzAA,3033
|
152
152
|
zrb/runner/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
153
|
-
zrb/runner/cli.py,sha256
|
154
|
-
zrb/runner/
|
153
|
+
zrb/runner/cli.py,sha256=xt33LMOX5tLWcc_jmeBsEdBu4xKlNiu0mtWzdR5T40Y,6408
|
154
|
+
zrb/runner/common_util.py,sha256=JYBgNPSGyJHZo0X-Qp9sDi4B14NdcTi20n1fJP4SW3M,1298
|
155
|
+
zrb/runner/web_app.py,sha256=SNDRKnWCOdJCQt00ZZkApFV7YnTKKXiC6W8F3dXJZzM,7076
|
155
156
|
zrb/runner/web_controller/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
156
157
|
zrb/runner/web_controller/group_info_ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
157
158
|
zrb/runner/web_controller/group_info_ui/controller.py,sha256=zRbbJpmpu6jX6iaEZUMgGmyaIgUd4wS9Entc8o5ZC14,2763
|
@@ -168,15 +169,15 @@ zrb/runner/web_controller/home_page/partial/task_info.html,sha256=dKHHuLIXi37XBb
|
|
168
169
|
zrb/runner/web_controller/home_page/partial/task_li.html,sha256=m-fs4VhbX27fZKgxBA0_Gv_Utntq5aaXD4sFk3zNMlk,61
|
169
170
|
zrb/runner/web_controller/home_page/view.html,sha256=RuYx2V52_kTzb4Fkjpc2H97ZpSvlSB8ElbMng2uMDUI,606
|
170
171
|
zrb/runner/web_controller/static/favicon-32x32.png,sha256=yu9AIU4k_qD4YHpul6XwJgOxIbmu0thv9ymm2QOsrAk,1456
|
171
|
-
zrb/runner/web_controller/static/pico.min.css,sha256=
|
172
|
+
zrb/runner/web_controller/static/pico.min.css,sha256=_Esfkjs_U_igYn-tXBUaK3AEKb7d4l9DlmaOiw9bXfI,82214
|
173
|
+
zrb/runner/web_controller/static/task-ui/common-util.js,sha256=t7_s5DXgMyZlT8L8LYZTkzOT6vWVeZvmCKjt-bflQY0,2117
|
174
|
+
zrb/runner/web_controller/static/task-ui/current-session.js,sha256=oA1OFWeRYJzowL8-5mMpy32m9hv-_T6MwAuVruP7XDw,6515
|
175
|
+
zrb/runner/web_controller/static/task-ui/event.js,sha256=NpFPV2kejUu_WSqfZgW57Un791L4NbmATujavcoIhrM,4217
|
176
|
+
zrb/runner/web_controller/static/task-ui/past-session.js,sha256=LP0ABMTm7Ap9t9G-JF4b_pRm7BCbh96D_IFb5p91FgA,5325
|
172
177
|
zrb/runner/web_controller/task_ui/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
173
|
-
zrb/runner/web_controller/task_ui/controller.py,sha256=
|
174
|
-
zrb/runner/web_controller/task_ui/partial/common-util.js,sha256=Un5HxlFMzNa16UBJZEWvEldFJaZpt6O3Qddd9Zlw0Io,931
|
178
|
+
zrb/runner/web_controller/task_ui/controller.py,sha256=UKYRTzGoSHQabsQeQBWfkmEnezn_DduWTdoQYUZ258A,2398
|
175
179
|
zrb/runner/web_controller/task_ui/partial/input.html,sha256=DDOCdHfwrU8ZF1SSNb0KDaQzbhzn-gipEGaa_ZH5k9I,154
|
176
|
-
zrb/runner/web_controller/task_ui/
|
177
|
-
zrb/runner/web_controller/task_ui/partial/show-existing-session.js,sha256=o5J-O5poWMIL1ujBXparwA4YalFuGXyA8S_wFw8obsM,3637
|
178
|
-
zrb/runner/web_controller/task_ui/partial/visualize-history.js,sha256=xKFmE-eXy9PXTWXhG_aQZ15DWStSGRrA8xzHntO-rmY,3916
|
179
|
-
zrb/runner/web_controller/task_ui/view.html,sha256=SARL-Dt03ar8IT9RJt7ULJLsjRm5u8K_F4VFwQwhxAs,2668
|
180
|
+
zrb/runner/web_controller/task_ui/view.html,sha256=E56ER5eg6nDyr3tk8r9aoAM2feoHk4utVR7OCVNLbX4,2681
|
180
181
|
zrb/runner/web_util.py,sha256=FBMnS7qMp31ogm0pCZBObNjrlopIwzYM7UuZjCX1n8Q,428
|
181
182
|
zrb/session/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
182
183
|
zrb/session/any_session.py,sha256=x57mS15E-AfUjdVxwOWEzCBjW32zjer7WoeBw0guoDc,5266
|
@@ -234,7 +235,7 @@ zrb/util/string/name.py,sha256=8picJfUBXNpdh64GNaHv3om23QHhUZux7DguFLrXHp8,1163
|
|
234
235
|
zrb/util/todo.py,sha256=1nDdwPc22oFoK_1ZTXyf3638Bg6sqE2yp_U4_-frHoc,16015
|
235
236
|
zrb/xcom/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
236
237
|
zrb/xcom/xcom.py,sha256=o79rxR9wphnShrcIushA0Qt71d_p3ZTxjNf7x9hJB78,1571
|
237
|
-
zrb-1.0.
|
238
|
-
zrb-1.0.
|
239
|
-
zrb-1.0.
|
240
|
-
zrb-1.0.
|
238
|
+
zrb-1.0.0a19.dist-info/METADATA,sha256=c1J13e4E41ixo8ME4QryDzpkEl7gst6QjsDhRdFPXZE,4106
|
239
|
+
zrb-1.0.0a19.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
240
|
+
zrb-1.0.0a19.dist-info/entry_points.txt,sha256=-Pg3ElWPfnaSM-XvXqCxEAa-wfVI6BEgcs386s8C8v8,46
|
241
|
+
zrb-1.0.0a19.dist-info/RECORD,,
|
@@ -1,37 +0,0 @@
|
|
1
|
-
function getFinalColor(finalStatus) {
|
2
|
-
switch(finalStatus) {
|
3
|
-
case "started":
|
4
|
-
return "#3498db";
|
5
|
-
case "ready":
|
6
|
-
return "#f39c12";
|
7
|
-
case "completed":
|
8
|
-
return "#2ecc71";
|
9
|
-
case "skipped":
|
10
|
-
return "#95a5a6";
|
11
|
-
case "failed":
|
12
|
-
return "#e74c3c";
|
13
|
-
case "permanently-failed":
|
14
|
-
return "#c0392b";
|
15
|
-
case "terminated":
|
16
|
-
return "#ffffff";
|
17
|
-
default:
|
18
|
-
return "#ffffff";
|
19
|
-
}
|
20
|
-
}
|
21
|
-
|
22
|
-
function getFinalTaskStatus(taskStatus) {
|
23
|
-
if (taskStatus.is_completed) {
|
24
|
-
return "completed";
|
25
|
-
}
|
26
|
-
if (taskStatus.is_terminated) {
|
27
|
-
return "terminated"
|
28
|
-
}
|
29
|
-
if (taskStatus.is_permanently_failed) {
|
30
|
-
return "permanently-failed"
|
31
|
-
}
|
32
|
-
const histories = taskStatus.history;
|
33
|
-
if (histories.length > 0) {
|
34
|
-
return histories[histories.length - 1].status;
|
35
|
-
}
|
36
|
-
return "";
|
37
|
-
}
|