Skip to content

Commit 9ea807a

Browse files
better solution for experiment profiles - send the full path in the api
1 parent a021f97 commit 9ea807a

File tree

9 files changed

+21
-14
lines changed

9 files changed

+21
-14
lines changed

asset-manifest.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"files": {
33
"main.css": "/static/css/main.02152627.css",
4-
"main.js": "/static/js/main.7f1e5adb.js",
4+
"main.js": "/static/js/main.48226022.js",
55
"static/media/roboto-all-500-normal.woff": "/static/media/roboto-all-500-normal.0ab669b7a0d19b178f57.woff",
66
"static/media/roboto-all-700-normal.woff": "/static/media/roboto-all-700-normal.a457fde362a540fcadff.woff",
77
"static/media/roboto-all-400-normal.woff": "/static/media/roboto-all-400-normal.c5d001fa922fa66a147f.woff",
@@ -36,10 +36,10 @@
3636
"static/media/roboto-greek-ext-700-normal.woff2": "/static/media/roboto-greek-ext-700-normal.bd9854c751441ccc1a70.woff2",
3737
"index.html": "/index.html",
3838
"main.02152627.css.map": "/static/css/main.02152627.css.map",
39-
"main.7f1e5adb.js.map": "/static/js/main.7f1e5adb.js.map"
39+
"main.48226022.js.map": "/static/js/main.48226022.js.map"
4040
},
4141
"entrypoints": [
4242
"static/css/main.02152627.css",
43-
"static/js/main.7f1e5adb.js"
43+
"static/js/main.48226022.js"
4444
]
4545
}

index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Pioreactor"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><script defer="defer" src="/static/js/main.7f1e5adb.js"></script><link href="/static/css/main.02152627.css" rel="stylesheet"></head><body><div id="root"></div></body></html>
1+
<!doctype html><html lang="en"><head><meta charset="utf-8"/><link rel="icon" href="/favicon.ico"/><meta name="viewport" content="width=device-width,initial-scale=1"/><meta name="theme-color" content="#000000"/><meta name="description" content="Pioreactor"/><link rel="apple-touch-icon" href="/logo192.png"/><link rel="manifest" href="/manifest.json"/><script defer="defer" src="/static/js/main.48226022.js"></script><link href="/static/css/main.02152627.css" rel="stylesheet"></head><body><div id="root"></div></body></html>

pioreactorui/__init__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -113,7 +113,7 @@ def handle_not_auth(e):
113113
@app.errorhandler(500)
114114
def handle_server_error(e):
115115
return (
116-
jsonify({"error": f"Internal server error: {e.description}. See logs for more."}),
116+
jsonify({"error": f"Internal server error: {e.description} - see logs for more."}),
117117
500,
118118
)
119119

pioreactorui/api.py

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1606,11 +1606,11 @@ def get_running_profiles(experiment: str) -> ResponseReturnValue:
16061606
json_group_array(json_object(
16071607
'job_name', m.job_name,
16081608
'experiment', m.experiment,
1609-
'job_id', m.id,
1609+
'job_id', m.job_id,
16101610
'settings', (
16111611
SELECT json_group_object(s.setting, s.value)
16121612
FROM pio_job_published_settings s
1613-
WHERE s.job_id = m.id
1613+
WHERE s.job_id = m.job_id
16141614
)
16151615
)) as result
16161616
FROM
@@ -1728,13 +1728,20 @@ def get_experiment_profiles() -> ResponseReturnValue:
17281728
"experiment_profile_name": f"temporary name: {file.stem}"
17291729
},
17301730
"file": Path(file).name,
1731+
"fullpath": Path(file).as_posix(),
17311732
}
17321733
)
17331734
continue
17341735

17351736
try:
17361737
profile = yaml_decode(file.read_bytes(), type=Profile)
1737-
parsed_yaml.append({"experimentProfile": profile, "file": Path(file).name})
1738+
parsed_yaml.append(
1739+
{
1740+
"experimentProfile": profile,
1741+
"file": Path(file).name,
1742+
"fullpath": Path(file).as_posix(),
1743+
}
1744+
)
17381745
except (ValidationError, DecodeError) as e:
17391746
publish_to_error_log(
17401747
f"Yaml error in {Path(file).name}: {e}", "get_experiment_profiles"

pioreactorui/unit_api.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -364,7 +364,7 @@ def get_settings_for_a_specific_job(job_name) -> ResponseReturnValue:
364364
SELECT s.setting, s.value FROM
365365
pio_job_published_settings s
366366
JOIN pio_job_metadata m
367-
on m.id = s.job_id
367+
on m.job_id = s.job_id
368368
WHERE m.is_running=1 AND m.job_name=(?);
369369
""",
370370
(job_name,),
@@ -383,7 +383,7 @@ def get_specific_setting_for_a_job(job_name, setting) -> ResponseReturnValue:
383383
SELECT s.setting, s.value FROM
384384
pio_job_published_settings s
385385
JOIN pio_job_metadata m
386-
on m.id = s.job_id
386+
on m.job_id = s.job_id
387387
WHERE m.is_running=1 AND m.job_name=(?) AND setting = (?)
388388
""",
389389
(job_name, setting),
Lines changed: 3 additions & 3 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

static/js/main.48226022.js.map

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

static/js/main.7f1e5adb.js.map

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)