edge-containers-cli 3.5.2__tar.gz → 3.5.3__tar.gz
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.
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/ci.yml +2 -2
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/PKG-INFO +3 -3
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/pyproject.toml +6 -5
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/_version.py +2 -2
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/k8s_commands.py +3 -3
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/monitor.py +43 -18
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/docker.py +2 -2
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/shell.py +2 -3
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/PKG-INFO +3 -3
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/conftest.py +2 -2
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.copier-answers.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.devcontainer/devcontainer.json +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/CONTRIBUTING.md +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/actions/install_requirements/action.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/dependabot.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/pages/index.html +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/pages/make_switcher.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_check.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_dist.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_pypi.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_release.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_sys_test.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_test.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.github/workflows/_tox.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.gitignore +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.pre-commit-config.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.vscode/extensions.json +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.vscode/launch.json +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.vscode/settings.json +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/.vscode/tasks.json +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/Dockerfile +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/LICENSE +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/README.md +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/catalog-info.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/conf.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/explanations/decisions/0001-record-architecture-decisions.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/explanations/decisions/0002-switched-to-pip-skeleton.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/explanations/decisions.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/build-docs.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/contribute.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/lint.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/make-release.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/pin-requirements.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/run-tests.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/static-analysis.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/test-container.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/update-tools.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/index.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/reference/standards.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/tutorials/dev-install.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/genindex.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/images/dls-favicon.ico +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/images/dls-logo.svg +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/index.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/explanations/docs-structure.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/how-to/run-container.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/index.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/reference/api.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/tutorials/installation.rst +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/setup.cfg +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/__init__.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/__main__.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/autocomplete.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/__init__.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/cli.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/commands.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/helm.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/kubectl.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/local_commands.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/monitor.tcss +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/git.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/globals.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/logging.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/utils.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/SOURCES.txt +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/dependency_links.txt +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/entry_points.txt +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/requires.txt +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/top_level.txt +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/__init__.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/autocomplete.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.copier-answers.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.github/dependabot.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.github/workflows/ci_verify.sh +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.github/workflows/verify.yml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.gitignore +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/LICENSE +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/README.md +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/environment.sh +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/Chart.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/README.md +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/values.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/include/iocs/Chart.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/include/iocs/templates/configmap.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/services/bl01t-ea-test-01/Chart.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/services/bl01t-ea-test-01/config/ioc.db +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/services/bl01t-ea-test-01/config/ioc.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/services/bl01t-ea-test-01/pretend_helm.tgz +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/services/bl01t-ea-test-01/values.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/update-helm +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/ioc.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/local.yaml +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/test_autocomplete.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/test_cli.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/test_ioc.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/test_local.py +0 -0
- {edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/test_system.py +0 -0
|
@@ -21,7 +21,7 @@ jobs:
|
|
|
21
21
|
strategy:
|
|
22
22
|
matrix:
|
|
23
23
|
runs-on: ["ubuntu-latest"] # can add windows-latest, macos-latest
|
|
24
|
-
python-version: ["3.
|
|
24
|
+
python-version: ["3.10", "3.11", "3.12"]
|
|
25
25
|
include:
|
|
26
26
|
# Include one that runs in the dev environment
|
|
27
27
|
- runs-on: "ubuntu-latest"
|
|
@@ -40,7 +40,7 @@ jobs:
|
|
|
40
40
|
strategy:
|
|
41
41
|
matrix:
|
|
42
42
|
runs-on: ["ubuntu-latest"]
|
|
43
|
-
python-version: ["3.
|
|
43
|
+
python-version: ["3.12"]
|
|
44
44
|
fail-fast: false
|
|
45
45
|
uses: ./.github/workflows/_sys_test.yml
|
|
46
46
|
with:
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: edge-containers-cli
|
|
3
|
-
Version: 3.5.
|
|
3
|
+
Version: 3.5.3
|
|
4
4
|
Summary: CLI for deploying and managing epics containers IOCs and services
|
|
5
5
|
Author-email: Giles Knap <giles.knap@gmail.com>
|
|
6
6
|
License: Apache License
|
|
@@ -208,10 +208,10 @@ License: Apache License
|
|
|
208
208
|
Project-URL: GitHub, https://github.com/epics-containers/edge-containers-cli
|
|
209
209
|
Classifier: Development Status :: 3 - Alpha
|
|
210
210
|
Classifier: License :: OSI Approved :: Apache Software License
|
|
211
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
212
211
|
Classifier: Programming Language :: Python :: 3.10
|
|
213
212
|
Classifier: Programming Language :: Python :: 3.11
|
|
214
|
-
|
|
213
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
214
|
+
Requires-Python: >=3.10
|
|
215
215
|
Description-Content-Type: text/markdown
|
|
216
216
|
License-File: LICENSE
|
|
217
217
|
Requires-Dist: natsort
|
|
@@ -7,9 +7,9 @@ name = "edge-containers-cli"
|
|
|
7
7
|
classifiers = [
|
|
8
8
|
"Development Status :: 3 - Alpha",
|
|
9
9
|
"License :: OSI Approved :: Apache Software License",
|
|
10
|
-
"Programming Language :: Python :: 3.9",
|
|
11
10
|
"Programming Language :: Python :: 3.10",
|
|
12
11
|
"Programming Language :: Python :: 3.11",
|
|
12
|
+
"Programming Language :: Python :: 3.12",
|
|
13
13
|
]
|
|
14
14
|
description = "CLI for deploying and managing epics containers IOCs and services"
|
|
15
15
|
|
|
@@ -26,7 +26,7 @@ dependencies = [
|
|
|
26
26
|
dynamic = ["version"]
|
|
27
27
|
license.file = "LICENSE"
|
|
28
28
|
readme = "README.md"
|
|
29
|
-
requires-python = ">=3.
|
|
29
|
+
requires-python = ">=3.10"
|
|
30
30
|
|
|
31
31
|
[project.optional-dependencies]
|
|
32
32
|
dev = [
|
|
@@ -109,9 +109,10 @@ commands =
|
|
|
109
109
|
src = ["src", "tests"]
|
|
110
110
|
line-length = 88
|
|
111
111
|
lint.ignore = [
|
|
112
|
-
"C408",
|
|
113
|
-
"E501",
|
|
114
|
-
"B008",
|
|
112
|
+
"C408", # Unnecessary collection call - e.g. list(...) instead of [...]
|
|
113
|
+
"E501", # Line too long, should be fixed by black.
|
|
114
|
+
"B008", # Do not perform function calls in argument defaults.
|
|
115
|
+
"UP007", # Do not complain about Optional[] (TODO: remove once typer is patched)
|
|
115
116
|
]
|
|
116
117
|
lint.select = [
|
|
117
118
|
"B", # flake8-bugbear - https://docs.astral.sh/ruff/rules/#flake8-bugbear-b
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/k8s_commands.py
RENAMED
|
@@ -7,7 +7,7 @@ Relies on the Helm class for deployment aspects.
|
|
|
7
7
|
from datetime import datetime
|
|
8
8
|
from io import StringIO
|
|
9
9
|
from pathlib import Path
|
|
10
|
-
from typing import Optional
|
|
10
|
+
from typing import Optional
|
|
11
11
|
|
|
12
12
|
import polars
|
|
13
13
|
import typer
|
|
@@ -39,7 +39,7 @@ def check_service(service_name: str, namespace: str) -> str:
|
|
|
39
39
|
return str(result).strip()
|
|
40
40
|
|
|
41
41
|
|
|
42
|
-
def check_namespace(namespace:
|
|
42
|
+
def check_namespace(namespace: str | None):
|
|
43
43
|
"""
|
|
44
44
|
Verify we have a good namespace that exists in the cluster
|
|
45
45
|
"""
|
|
@@ -125,7 +125,7 @@ class K8sCommands(Commands):
|
|
|
125
125
|
|
|
126
126
|
def logs(
|
|
127
127
|
self, service_name: str, prev: bool, follow: bool, stdout: bool = False
|
|
128
|
-
) -> Optional[
|
|
128
|
+
) -> Optional[str | bool]:
|
|
129
129
|
fullname = check_service(service_name, self.namespace)
|
|
130
130
|
previous = "-p" if prev else ""
|
|
131
131
|
fol = "-f" if follow else ""
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/monitor.py
RENAMED
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
"""TUI monitor for containerised IOCs."""
|
|
2
2
|
|
|
3
|
+
from collections.abc import Callable
|
|
3
4
|
from functools import total_ordering
|
|
4
5
|
from threading import Thread
|
|
5
6
|
from time import sleep
|
|
6
|
-
from typing import Any,
|
|
7
|
+
from typing import Any, cast
|
|
7
8
|
|
|
8
9
|
import polars
|
|
9
10
|
from rich.style import Style
|
|
@@ -185,17 +186,41 @@ class SortableText(Text):
|
|
|
185
186
|
def __lt__(self, other: Any) -> bool:
|
|
186
187
|
if type(other) != SortableText:
|
|
187
188
|
return NotImplemented
|
|
188
|
-
|
|
189
|
+
|
|
190
|
+
# Handle None as values
|
|
191
|
+
match self.value, other.value:
|
|
192
|
+
case (None, None) | (None, _):
|
|
193
|
+
return False
|
|
194
|
+
case (_, None):
|
|
195
|
+
return True
|
|
196
|
+
case _:
|
|
197
|
+
return cast(bool, self.value < other.value)
|
|
189
198
|
|
|
190
199
|
def __gt__(self, other: Any) -> bool:
|
|
191
200
|
if type(other) != SortableText:
|
|
192
201
|
return NotImplemented
|
|
193
|
-
|
|
202
|
+
|
|
203
|
+
# Handle None as values
|
|
204
|
+
match self.value, other.value:
|
|
205
|
+
case (None, None) | (_, None):
|
|
206
|
+
return False
|
|
207
|
+
case (None, _):
|
|
208
|
+
return True
|
|
209
|
+
case _:
|
|
210
|
+
return cast(bool, self.value > other.value)
|
|
194
211
|
|
|
195
212
|
def __eq__(self, other: Any) -> bool:
|
|
196
213
|
if type(other) != SortableText:
|
|
197
214
|
return NotImplemented
|
|
198
|
-
|
|
215
|
+
|
|
216
|
+
# Handle None as values
|
|
217
|
+
match self.value, other.value:
|
|
218
|
+
case (None, _) | (_, None):
|
|
219
|
+
return False
|
|
220
|
+
case (None, None):
|
|
221
|
+
return True
|
|
222
|
+
case _:
|
|
223
|
+
return cast(bool, self.value == other.value)
|
|
199
224
|
|
|
200
225
|
|
|
201
226
|
class IocTable(Widget):
|
|
@@ -240,7 +265,7 @@ class IocTable(Widget):
|
|
|
240
265
|
self.iocs[i] = ioc
|
|
241
266
|
self.columns = [key for key in self.iocs[0].keys() if key not in exclude]
|
|
242
267
|
|
|
243
|
-
def _convert_df_to_list(self, iocs_df:
|
|
268
|
+
def _convert_df_to_list(self, iocs_df: polars.DataFrame | list) -> list[dict]:
|
|
244
269
|
if isinstance(iocs_df, polars.DataFrame):
|
|
245
270
|
iocs = iocs_df.to_dicts()
|
|
246
271
|
else:
|
|
@@ -353,18 +378,6 @@ class IocTable(Widget):
|
|
|
353
378
|
|
|
354
379
|
|
|
355
380
|
class MonitorApp(App):
|
|
356
|
-
def __init__(
|
|
357
|
-
self,
|
|
358
|
-
beamline: str,
|
|
359
|
-
commands: Commands,
|
|
360
|
-
running_only: bool,
|
|
361
|
-
) -> None:
|
|
362
|
-
super().__init__()
|
|
363
|
-
|
|
364
|
-
self.commands = commands
|
|
365
|
-
self.running_only = running_only
|
|
366
|
-
self.beamline = beamline
|
|
367
|
-
|
|
368
381
|
CSS_PATH = "monitor.tcss"
|
|
369
382
|
|
|
370
383
|
BINDINGS = [
|
|
@@ -377,6 +390,18 @@ class MonitorApp(App):
|
|
|
377
390
|
# Binding("d", "toggle_dark", "Toggle dark mode"),
|
|
378
391
|
]
|
|
379
392
|
|
|
393
|
+
def __init__(
|
|
394
|
+
self,
|
|
395
|
+
beamline: str,
|
|
396
|
+
commands: Commands,
|
|
397
|
+
running_only: bool,
|
|
398
|
+
) -> None:
|
|
399
|
+
super().__init__()
|
|
400
|
+
|
|
401
|
+
self.commands = commands
|
|
402
|
+
self.running_only = running_only
|
|
403
|
+
self.beamline = beamline
|
|
404
|
+
|
|
380
405
|
def compose(self) -> ComposeResult:
|
|
381
406
|
"""Create child widgets for the app."""
|
|
382
407
|
yield Header(show_clock=True)
|
|
@@ -409,7 +434,7 @@ class MonitorApp(App):
|
|
|
409
434
|
col_keys = [ord_col.key.value for ord_col in table.ordered_columns]
|
|
410
435
|
col_i = col_keys.index(col_key)
|
|
411
436
|
ioc_col = table.ordered_columns[col_i]
|
|
412
|
-
cell:
|
|
437
|
+
cell: str | SortableText = table.get_cell(ioc_row.key, ioc_col.key)
|
|
413
438
|
# SortableText inherits __str__() from Text
|
|
414
439
|
return str(cell)
|
|
415
440
|
|
|
@@ -5,7 +5,7 @@ Utility functions for working interacting with docker / podman CLI
|
|
|
5
5
|
import re
|
|
6
6
|
from pathlib import Path
|
|
7
7
|
from time import sleep
|
|
8
|
-
from typing import Optional
|
|
8
|
+
from typing import Optional
|
|
9
9
|
|
|
10
10
|
import typer
|
|
11
11
|
|
|
@@ -111,7 +111,7 @@ class Docker:
|
|
|
111
111
|
previous: bool = False,
|
|
112
112
|
follow: bool = False,
|
|
113
113
|
stdout: bool = False,
|
|
114
|
-
) -> Optional[
|
|
114
|
+
) -> Optional[str | bool]:
|
|
115
115
|
"""
|
|
116
116
|
show logs from a container
|
|
117
117
|
"""
|
|
@@ -3,7 +3,6 @@ functions for executing commands and querying environment in the linux shell
|
|
|
3
3
|
"""
|
|
4
4
|
|
|
5
5
|
import subprocess
|
|
6
|
-
from typing import Union
|
|
7
6
|
|
|
8
7
|
import typer
|
|
9
8
|
from rich.console import Console
|
|
@@ -39,7 +38,7 @@ def echo_output(output: str):
|
|
|
39
38
|
|
|
40
39
|
def run_command(
|
|
41
40
|
command: str, interactive=True, error_OK=False, show=False
|
|
42
|
-
) ->
|
|
41
|
+
) -> str | bool:
|
|
43
42
|
"""
|
|
44
43
|
Run a command and return the output
|
|
45
44
|
|
|
@@ -65,7 +64,7 @@ def run_command(
|
|
|
65
64
|
error_out = p_result.stderr.decode()
|
|
66
65
|
|
|
67
66
|
if interactive:
|
|
68
|
-
result:
|
|
67
|
+
result: str | bool = p_result.returncode == 0
|
|
69
68
|
else:
|
|
70
69
|
result = output + error_out
|
|
71
70
|
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/PKG-INFO
RENAMED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: edge-containers-cli
|
|
3
|
-
Version: 3.5.
|
|
3
|
+
Version: 3.5.3
|
|
4
4
|
Summary: CLI for deploying and managing epics containers IOCs and services
|
|
5
5
|
Author-email: Giles Knap <giles.knap@gmail.com>
|
|
6
6
|
License: Apache License
|
|
@@ -208,10 +208,10 @@ License: Apache License
|
|
|
208
208
|
Project-URL: GitHub, https://github.com/epics-containers/edge-containers-cli
|
|
209
209
|
Classifier: Development Status :: 3 - Alpha
|
|
210
210
|
Classifier: License :: OSI Approved :: Apache Software License
|
|
211
|
-
Classifier: Programming Language :: Python :: 3.9
|
|
212
211
|
Classifier: Programming Language :: Python :: 3.10
|
|
213
212
|
Classifier: Programming Language :: Python :: 3.11
|
|
214
|
-
|
|
213
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
214
|
+
Requires-Python: >=3.10
|
|
215
215
|
Description-Content-Type: text/markdown
|
|
216
216
|
License-File: LICENSE
|
|
217
217
|
Requires-Dist: natsort
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import re
|
|
2
2
|
import shutil
|
|
3
|
+
from collections.abc import Callable
|
|
3
4
|
from pathlib import Path
|
|
4
5
|
from types import SimpleNamespace
|
|
5
|
-
from typing import Callable, Union
|
|
6
6
|
|
|
7
7
|
from pytest import fixture
|
|
8
8
|
from ruamel.yaml import YAML
|
|
@@ -73,7 +73,7 @@ class MockRun:
|
|
|
73
73
|
|
|
74
74
|
return rsp
|
|
75
75
|
|
|
76
|
-
def set_seq(self, cmd_rsp: list[dict[str,
|
|
76
|
+
def set_seq(self, cmd_rsp: list[dict[str, str | bool]]):
|
|
77
77
|
"""
|
|
78
78
|
Set up the expected sequence of commands that we expect to see come
|
|
79
79
|
through the mock of run_command. Also supplies the response to
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/explanations/decisions.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/build-docs.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/contribute.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/make-release.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/pin-requirements.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/static-analysis.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/test-container.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/how-to/update-tools.rst
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/reference/standards.rst
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/developer/tutorials/dev-install.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/explanations/docs-structure.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/docs/user/tutorials/installation.rst
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/autocomplete.py
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/__init__.py
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/commands.py
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/helm.py
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/kubectl.py
RENAMED
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli/cmds/monitor.tcss
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/src/edge_containers_cli.egg-info/SOURCES.txt
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.copier-answers.yml
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/.github/dependabot.yml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/Chart.yaml
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/README.md
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/helm/shared/values.yaml
RENAMED
|
File without changes
|
{edge_containers_cli-3.5.2 → edge_containers_cli-3.5.3}/tests/data/bl01t/include/iocs/Chart.yaml
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|