From e7b665468d7e010cc0deeace69bf38135e600833 Mon Sep 17 00:00:00 2001 From: sgoral Date: Mon, 30 Sep 2024 13:47:43 +0200 Subject: [PATCH 1/9] chore: split subprocess_call and subporcess_run into separate functions --- .../install_python_libraries.py | 58 ++++++++++++++++--- 1 file changed, 51 insertions(+), 7 deletions(-) diff --git a/splunk_add_on_ucc_framework/install_python_libraries.py b/splunk_add_on_ucc_framework/install_python_libraries.py index 6d73eb69a..d0c3bbcfd 100644 --- a/splunk_add_on_ucc_framework/install_python_libraries.py +++ b/splunk_add_on_ucc_framework/install_python_libraries.py @@ -20,6 +20,8 @@ import subprocess import sys from pathlib import Path + +from packaging.version import Version from typing import List, Optional, Set, Iterable, Dict from splunk_add_on_ucc_framework.global_config import OSDependentLibraryConfig @@ -34,6 +36,10 @@ class CouldNotInstallRequirements(Exception): pass +class InvalidArguments(Exception): + pass + + def _subprocess_call( command: str, command_desc: Optional[str] = None, @@ -55,6 +61,24 @@ def _subprocess_call( raise e +def _subprocess_run( + command: str, + command_desc: Optional[str] = None, + env: Optional[Dict[str, str]] = None, +) -> subprocess.CompletedProcess[bytes]: + command_desc = command_desc or command + try: + logger.info(f"Executing: {command}") + process_result = subprocess.run( + command, shell=True, env=env, capture_output=True + ) + return process_result + + except OSError as e: + logger.error(f"Execution ({command_desc}) failed due to {e}") + raise e + + def _pip_install(installer: str, command: str, command_desc: str) -> None: cmd = f"{installer} -m pip install {command}" try: @@ -66,18 +90,36 @@ def _pip_install(installer: str, command: str, command_desc: str) -> None: def _pip_is_lib_installed( - installer: str, target: str, libname: str, version: Optional[str] = None + installer: str, + target: str, + libname: str, + version: Optional[str] = None, + allow_higher_version: bool = False, ) -> bool: + if not version and allow_higher_version: + raise InvalidArguments( + "Parameter 'allow_higher_version' can not be set to True if 'version' parameter is not provided" + ) + lib_installed_cmd = f"{installer} -m pip show --version {libname}" - lib_version_match_cmd = f'{lib_installed_cmd} | grep "Version: {version}"' - cmd = lib_version_match_cmd if version else lib_installed_cmd + if version and allow_higher_version: + cmd = f'{lib_installed_cmd} | grep "Version"' + elif version and not allow_higher_version: + cmd = f'{lib_installed_cmd} | grep "Version: {version}"' + else: + cmd = lib_installed_cmd try: my_env = os.environ.copy() my_env["PYTHONPATH"] = target - return_code = _subprocess_call(command=cmd, env=my_env) - return return_code == 0 + if allow_higher_version: + result = _subprocess_run(command=cmd, env=my_env) + result_version = result.stdout.decode("utf-8").split("Version:")[1].strip() + return Version(result_version) >= Version(version) + else: + return_code = _subprocess_call(command=cmd, env=my_env) + return return_code == 0 except OSError as e: raise CouldNotInstallRequirements from e @@ -116,10 +158,12 @@ def install_python_libraries( installer=python_binary_name, target=ucc_lib_target, libname="splunktaucclib", + version="6.4", + allow_higher_version=True, ): raise SplunktaucclibNotFound( - f"splunktaucclib is not found in {path_to_requirements_file}. " - f"Please add it there because this add-on has UI." + f"splunktaucclib is not found in {path_to_requirements_file} or has invalid version. " + f"Please add it there and check if it is at least version 6.4, because this add-on has UI." ) cleanup_libraries = install_os_dependent_libraries( From 4ab520ff67a36cd3f42d74b2c2b269aa07968840 Mon Sep 17 00:00:00 2001 From: srv-rr-github-token <94607705+srv-rr-github-token@users.noreply.github.com> Date: Mon, 14 Oct 2024 08:28:57 +0000 Subject: [PATCH 2/9] update screenshots --- .../stories/__images__/AcceptModal-base-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-both-oauth-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-oauth-oauth-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-ouath-basic-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-base-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-create-mode-chromium.png | 4 ++-- .../__images__/CheckboxGroup-input-page-view-chromium.png | 4 ++-- .../__images__/CheckboxGroup-mixed-with-groups-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-multiline-chromium.png | 4 ++-- .../__images__/CheckboxGroup-required-view-chromium.png | 4 ++-- .../__images__/CheckboxGroup-with-single-group-chromium.png | 4 ++-- .../stories/__images__/ControlWrapper-base-chromium.png | 4 ++-- .../stories/__images__/DeleteModal-base-chromium.png | 4 ++-- .../stories/__images__/DeleteModal-inputs-chromium.png | 4 ++-- .../stories/__images__/DownloadButton-base-chromium.png | 4 ++-- .../stories/__images__/EntityModal-base-chromium.png | 4 ++-- .../stories/__images__/EntityModal-inputs-chromium.png | 4 ++-- .../stories/__images__/EntityPage-base-chromium.png | 4 ++-- .../stories/__images__/EntityPage-inputs-chromium.png | 4 ++-- .../stories/__images__/ErrorBoundary-base-chromium.png | 4 ++-- .../stories/__images__/ErrorModal-base-chromium.png | 4 ++-- .../stories/__images__/FileInputComponent-base-chromium.png | 4 ++-- ...ileInputComponent-encrypted-with-default-name-chromium.png | 4 ++-- .../FileInputComponent-with-default-name-chromium.png | 4 ++-- .../Group/stories/__images__/Group-base-chromium.png | 4 ++-- .../Group/stories/__images__/Group-expandable-chromium.png | 4 ++-- .../stories/__images__/HelpLinkComponent-base-chromium.png | 4 ++-- .../stories/__images__/MarkdownMessage-base-chromium.png | 4 ++-- .../MenuInput/stories/__images__/MenuInput-base-chromium.png | 4 ++-- .../stories/__images__/MenuInput-with-sub-menu-chromium.png | 4 ++-- .../__images__/MultiInputComponent-all-props-chromium.png | 4 ++-- .../stories/__images__/MultiInputComponent-base-chromium.png | 4 ++-- .../__images__/MultiInputComponent-endpoint-api-chromium.png | 4 ++-- .../stories/__images__/PlaceholderComponent-base-chromium.png | 4 ++-- .../stories/__images__/RadioComponent-base-chromium.png | 4 ++-- .../SingleInputComponent-accept-any-input-chromium.png | 4 ++-- ...leInputComponent-allow-deny-list-from-backend-chromium.png | 4 ++-- .../__images__/SingleInputComponent-select-list-chromium.png | 4 ++-- .../stories/__images__/SubDescription-base-chromium.png | 4 ++-- .../stories/__images__/TableWrapper-ouath-basic-chromium.png | 4 ++-- .../ConfigurationPage-configuration-page-view-chromium.png | 4 ++-- .../__images__/DashboardPage-dashboard-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-page-expanded-row-chromium.png | 4 ++-- .../__images__/InputPage-input-page-view-add-chromium.png | 4 ++-- .../stories/__images__/InputPage-input-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-tab-view-add-chromium.png | 4 ++-- ...obalConfigPlayground-global-config-playground-chromium.png | 4 ++-- 47 files changed, 94 insertions(+), 94 deletions(-) diff --git a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png index e3523ce17..f33eb8b6e 100644 --- a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png +++ b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b90c15d31812b868553f5569cf1c3e4751e0fcf228d6f06635f3fa645be2e9e -size 16164 +oid sha256:fb678ceca7aabaaec25704e1370f8a9fe1d143e74a50753be7a217aae06d8f79 +size 15825 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png index efdd66f37..2c7c0ea03 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3f136e6822bccfb0351eae671d1c4e89ac9b0070f7095d0e9bcd6988eb9c7699 -size 31173 +oid sha256:0d57ea3c23b0bef7edd03939349cbadeefe87ac01fca540ad5f7645ee2ed3e8a +size 29589 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png index bef678c9a..8d89fa1b6 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6a5530efff9a39297d24d18887a7099ae14b8428aef261ecffc6300c925560d2 -size 44888 +oid sha256:d51f70cb960cdf8c14233f9cd8272931aae7886e463c09a8b6668ba8c292c860 +size 42721 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png index 3ce1e412a..7481f88f3 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:23a31401d799e69c31fbae3b5d460c171c2746ee6bdbebdc73fbdd1e4b72ac34 -size 27208 +oid sha256:2f9f69ce12d2e1149c37eede319e6640506c2f2a5c36738874352a8c2bd2cd9c +size 25784 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png index 592edf7a6..309bd6a0e 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5f622a709b2e0c9cb0676831796ed6f4fe11824bfc62a285d8630f3e57deb2a9 -size 16998 +oid sha256:aa1ba903b2f244b4eef71791137bf8069c80eb7e8df5a86b09444abe9d26abea +size 16271 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png index f33ae6e42..728e98dcf 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5b352ab6169c33388a243bb7192e140b6a675ea779b371169e14747e7ba47c34 -size 13644 +oid sha256:2680562dfc2b43a68f77ea9af0cc5b6ed0dedca754f05dcfd7ec37757968302f +size 13205 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png index 8c9d0ffff..c138bf75b 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ba82abe77bd2a19627d3ca369ea967d124df0587a0c4975e471a567863a1fc11 -size 35401 +oid sha256:4ad6aa336b99ee6b0a5466feb443c7a25bfedf73db6a0cbf42f3b6ab52fdd66a +size 34452 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png index 78dba2025..a78c08ac8 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7699985e66e315c507cdc7f00426a1e9d6d81fb9f926071b2d5ca6b594c1d5d9 -size 24630 +oid sha256:a00b0a73c2717429294b3b383933d4721af6daa43bc1d8bffc9dc69816b162c5 +size 23336 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png index 146fcf304..f73c96c53 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d1eb78f2d8a89f8562ed6ea4cc51815dca7c7d502740d49301dee847a7b596a3 -size 22434 +oid sha256:0d02fce78ce6ff2e1ea2a39ee242d6e3eec9554cf363d1352084149a16f7e9b3 +size 20960 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png index 29fc7a258..898bb8597 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:75dcf61492b5842f47d360c4a8e40641c9f84a4ad3a147d69c6ea4abf89f1ef8 -size 42188 +oid sha256:d76af67b2eb2d1f0cd1d9b4aecf93e450dd5214d14c6bc47c4032cd18e43c573 +size 40558 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png index e928ae6dc..834b73743 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c1cff901be8b049e45f8245f15b53b870c6923ea57502e428aa196258036df49 -size 13597 +oid sha256:585b056c9ba9abd1ab3c7df6ee96479b49c1f5aa5cf30ecd7ac82fbc1f068c1c +size 13122 diff --git a/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png b/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png index 3c510e1e8..5e8e39b31 100644 --- a/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png +++ b/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c216dc3fb057054798ac053d8349c861901a399fb462b1b4f3966ae776b9339b -size 17144 +oid sha256:dc09f9fa0685c357ddcb83187e830adc7c556b6d4b97e98a80c8b86378909461 +size 16330 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png index a0acd3c45..6d6f6218a 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:470412651d90dc22b69b3abb4cc571cb2cfe2f405916953e855eb2fc522c8762 -size 22865 +oid sha256:2be45fb23b6427ef8f49c407773fcd827684092fe702ec5139a8c84a052886c6 +size 21540 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png index 44f83b10e..7abe9a91a 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:32ae042f3b360b1559846060d4f9e6ee419786a52c5ca5cdd26419fa30cd0fff -size 16369 +oid sha256:54652616281a37cd5c7a357ca1ed9dfde156613c451b9a93842d4b38847ce463 +size 15889 diff --git a/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png b/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png index 84ec7b190..8efe7eb4c 100644 --- a/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png +++ b/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9e9c700686f86996d1e5a045ff85020f3fe74a9cd38aba3daeb535edfa5b9975 -size 5350 +oid sha256:86c3a5ea9a168f03903a1598824e95457d352c12f6299473ccb23e485d4f70b2 +size 5273 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png index 489dabd78..913799dda 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:471744a25ce5b359263b7f9aa53db461a77590f7422492a5e2287cd6758a8e3b -size 22561 +oid sha256:d3ca2caa0d2aadc6c365f945527ecf55d5049aa574137e7cf8cdc9d334049282 +size 21760 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png index 82b592cf0..4245ac3c8 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:56be9cafa0bcad4cb68c9a4c8135d93948637e6a72be601b0e2f8100effa29ed -size 28532 +oid sha256:411c0a64aec50eb9162f40a504e792b7aaf9e7dc12bb11b7bc15286dae2f7741 +size 27508 diff --git a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png index 4d9e2ee1e..afa11306a 100644 --- a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png +++ b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:91648fa6f8ac5d712924f25cbf62d544b2364fcb69ed8baf53ae5392decf8503 -size 23434 +oid sha256:f1a02b87e3c93284b1e935812ee0bbebe923e229ce9ceb2267ebb51885dd41e4 +size 22515 diff --git a/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png b/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png index 15351fad0..ffcebbacf 100644 --- a/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png +++ b/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8b00f8c345b476e49e1fa4b84359bc34f95fa956d7d545b2bc2033bb3af3d54b -size 28254 +oid sha256:e2daa11543457c1a38758b9492c60bad0ff7a8f2dd72241c2ceaa94ae0cc3769 +size 27194 diff --git a/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png b/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png index 09f91ec34..83b0d2db9 100644 --- a/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png +++ b/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b99352a6e8b6de186ab2748bfa51090c36db5b2252340a8475ef4abdc733d594 -size 13128 +oid sha256:7ba5f992968fea84827106a82772f4f9ac93caaeed92ad48fdd89e64cefbe500 +size 12710 diff --git a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png index a2e7cf9a1..6c2ba999a 100644 --- a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png +++ b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:68c875054edea5fa11b31b2a0779afbf6fd8f9944a7a3c6d699a0ce880842cf2 -size 11823 +oid sha256:cdaecce434f5ad644e2560532bcf3e167323e63721b34c47f4c336085bf05fc5 +size 11571 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png index 47baecc7d..963e1614e 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0bdbcdfacb6100ee33aada803d9b85efc6cec76df6cb6ed0ea15fb61478c9dde -size 8379 +oid sha256:f77db7c515972f0811be9b48627d0672ce09c9893593794aa7b7b751d6591b07 +size 8033 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png index d896a344c..c8c517463 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:3a35017793237885e55d1c82930b4c47efbbd3cc14fd751e320647278e4160f8 -size 13098 +oid sha256:e2e5bb7dc88e818a6330b4fce19c2d1b3df5ef30fd587fbfea21d5548c4d018f +size 12482 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png index 227dade1f..e87a98acf 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9fbff82c2757375c53fc35dcb7110a30cddc33b95222db356885c089a58aa104 -size 10993 +oid sha256:bbb371b7a94a5d0f758454f4d1296cdcd7e3088da48efdeeaa0583ec2ee2bccb +size 10586 diff --git a/ui/src/components/Group/stories/__images__/Group-base-chromium.png b/ui/src/components/Group/stories/__images__/Group-base-chromium.png index e96178ba8..0be6da412 100644 --- a/ui/src/components/Group/stories/__images__/Group-base-chromium.png +++ b/ui/src/components/Group/stories/__images__/Group-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:14af50ceb9760f7b66fd7e6b0ba87a5378acb17c0014b99734265695c3da42b3 -size 9336 +oid sha256:075ae64e82bcc4512e0f0937ce0ba6c2e52a79a68b00d275d9bcd65448cead72 +size 8895 diff --git a/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png b/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png index 992ba4129..128ee56f4 100644 --- a/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png +++ b/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:573f9fe8e97b021dafa0b1f79adcedb9161be15ead2d311b0e582ef38dee5dee -size 8942 +oid sha256:d1acf1fb9e0f46d6b3405f61dcaf45cdb8d5dd7be3ada47220e34e88245c8290 +size 8471 diff --git a/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png b/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png index bd68383df..37db5ab34 100644 --- a/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png +++ b/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdf734626357c127f64d0a3aaa40ae939b40b4ffe750f9cea0ac0a398372652f -size 5490 +oid sha256:8ad3c989d8ead512fd3daa6fb0193b75663de13d8f4dc1e6bc078fe6349de028 +size 5400 diff --git a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png index 0261ee8f3..6d8f11bfc 100644 --- a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png +++ b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a3d5ccce46345708f0c487044dca718a9f203471bf28cf48a436c6abef3286c -size 1607 +oid sha256:d64bd81f64d395fb3b6dc3dfc5d265bae0d4a75ec1257a05c06dba517e1b1851 +size 1437 diff --git a/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png b/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png index 050717726..d9df1c57a 100644 --- a/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png +++ b/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a75a1f75e19664a958350775ff50ea4d8cbeb1980aafaaba2d0f1c41c105779 -size 6006 +oid sha256:4557ef290d4fa43312519e79a78c19fb2879f62f799d9b465faa45099d1171a3 +size 5932 diff --git a/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png b/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png index 050717726..d9df1c57a 100644 --- a/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png +++ b/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9a75a1f75e19664a958350775ff50ea4d8cbeb1980aafaaba2d0f1c41c105779 -size 6006 +oid sha256:4557ef290d4fa43312519e79a78c19fb2879f62f799d9b465faa45099d1171a3 +size 5932 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png index bfe572d9a..a73149321 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43b31c53bc97909f7839c5e3850b8637b3dcef6e7609a99b722edabe54bd9b6e -size 4494 +oid sha256:bdf1f9b4b905d2d3a276ce9e0e25bc3f0928e3929c0a9085aeefa40d2f974fc0 +size 4410 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png index bfe572d9a..a73149321 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:43b31c53bc97909f7839c5e3850b8637b3dcef6e7609a99b722edabe54bd9b6e -size 4494 +oid sha256:bdf1f9b4b905d2d3a276ce9e0e25bc3f0928e3929c0a9085aeefa40d2f974fc0 +size 4410 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png index ef8e7bc39..fa9ea7a97 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ede2226dd7b8cb2eae603512060a9343c7a33b15f2f93ef2126dbee197c112c1 -size 4494 +oid sha256:19937b12227641701bf54ecded7021c27a51319e2d979e6d3c6253d2e28c9754 +size 4410 diff --git a/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png b/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png index 77c0dafcc..98c3ad468 100644 --- a/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png +++ b/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c81ff53f649988b87ab58c8a18c82657c14311bd68d3f48a9e673dfcb81313d9 -size 4872 +oid sha256:2823cdf2a6f6d94a6e569f3766bac3b31149db9115a9cc7eaee06b61b07374bc +size 4701 diff --git a/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png b/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png index d0712db89..3f623c5f4 100644 --- a/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png +++ b/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:747ee92b01175dc4af79b063d2e377d6329b1ae9d198108a7385cd2d1019a484 -size 6094 +oid sha256:6e44375de1b0e8cb076b4a4488f0d7789b2bbe0af24789387fe8440f9f776210 +size 5932 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png index 401b2c00b..4d2b71edc 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec8e1e95fac3fc5f8bdc090c6ecaa449c01227b53a96acc91e114c2995a306f6 -size 4606 +oid sha256:ca4a7b129c4eccf7444e0510ada0ecce566cb04f213799dfc67020b60e7256b1 +size 4535 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png index 401b2c00b..4d2b71edc 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec8e1e95fac3fc5f8bdc090c6ecaa449c01227b53a96acc91e114c2995a306f6 -size 4606 +oid sha256:ca4a7b129c4eccf7444e0510ada0ecce566cb04f213799dfc67020b60e7256b1 +size 4535 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png index 306fd1a00..3320f9f1f 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ec2385e021d2b5c59666406ce756a8967f0dd34e056cdb6c51f864fc10ab77a0 -size 4606 +oid sha256:58597a3121696b8e8e62aa8cff59f314204e640f3ee81266ffd4e71634a25111 +size 4535 diff --git a/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png b/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png index c3f6ab2d2..5396fc3ee 100644 --- a/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png +++ b/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:864e63a6dd8d49fbf063ce72abcb93c21e528f778c99e5574b1c63bf04f20f0e -size 37365 +oid sha256:e791b6f762cd7db73a5bfea37ef11d5f830bf2929f1ab2badd27fbbe44d70e16 +size 35285 diff --git a/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png b/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png index 0ce27c13f..871c2b7ae 100644 --- a/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png +++ b/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:be0a6fe4a2d07cfdf32ba7724158dff463ac459a327e8cc29c18543796ba5cab -size 25440 +oid sha256:dd3ab6ecfca701dce02b1a1c38bb23dca834d3c7926fe1d3fd79194511635d97 +size 24972 diff --git a/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png b/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png index 046f648b0..3a16bdec9 100644 --- a/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png +++ b/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8d4895cbb18b7cbc661c4935325f344549f1949ea7c01a7d3f90be5547f984ce -size 59002 +oid sha256:d213a73d5dd1768ff7d66bc062650b83a194cc22787591506fca40fc1ef66c5e +size 56020 diff --git a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png index aef1ca1ac..33616af17 100644 --- a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png +++ b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:17c26b26a1e89743412d372462e05c4df6c4132583e6925531851ca44c789e8b -size 83057 +oid sha256:9bc77374f54d30126f91e549935645420aa3e8620cc71531325fda4ff096d095 +size 79758 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png index 7c8be001e..8938dbd69 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:da66686cf67903cc17c782b3e7e34b3b7374de528b273db993f4d0a66f6b4525 -size 47539 +oid sha256:bc79a4c99df71876e77cb71e7d9e4e2bbcb61b74c8ecaf95c681ef4c026a687f +size 46100 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png index 8f1188576..a4e2ca393 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:60afb91e9133f946070c37500495bb20830040b828ee59540c3aa23d1d5e473c -size 72703 +oid sha256:fb54998598b3aa242cfe62b4cc4a138c9f4717e210abf1f28311bfc9d5670749 +size 70930 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png index e8edddd23..a5fe467f5 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1af6a372d92392853b636aafacf8ef8f1510af947688dc42b5fa7f3dfbb8169b -size 40184 +oid sha256:c8a29a7a2bc67e9a7f089d7a15a6326928f32c34c8ba4e594f79b4db5cf52968 +size 39328 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png index 073b8da55..3416ddc40 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6e7c5bfa0d54800282eb59294c040de3b7a7d1fe4d4be35ca24740acdcd89ece -size 63504 +oid sha256:c43edb70928ccabc2e2ac5ce07c6c564be79620a4c9e881acaa517aaf1fcec2d +size 60740 diff --git a/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png b/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png index 9be0aae12..563e257c4 100644 --- a/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png +++ b/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:68ddd13b7feccb5aac38c0215dc12645198341bed1f4793bcd8009913476284b -size 62321 +oid sha256:da13e2722849499cdd7c7c79ad3bebcfd3f61177e4ea1b4688daec69cdb1d6ef +size 59082 From 70bf7553e313020d26cb0f028c05f8418c6313ad Mon Sep 17 00:00:00 2001 From: sgoral Date: Mon, 14 Oct 2024 14:06:49 +0200 Subject: [PATCH 3/9] test: fix typing --- splunk_add_on_ucc_framework/install_python_libraries.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/splunk_add_on_ucc_framework/install_python_libraries.py b/splunk_add_on_ucc_framework/install_python_libraries.py index d0c3bbcfd..3904b682d 100644 --- a/splunk_add_on_ucc_framework/install_python_libraries.py +++ b/splunk_add_on_ucc_framework/install_python_libraries.py @@ -65,7 +65,7 @@ def _subprocess_run( command: str, command_desc: Optional[str] = None, env: Optional[Dict[str, str]] = None, -) -> subprocess.CompletedProcess[bytes]: +) -> "subprocess.CompletedProcess[bytes]": command_desc = command_desc or command try: logger.info(f"Executing: {command}") From ea62838edf71b59b4471b43c4ff38ab888628c90 Mon Sep 17 00:00:00 2001 From: srv-rr-github-token <94607705+srv-rr-github-token@users.noreply.github.com> Date: Mon, 14 Oct 2024 12:12:32 +0000 Subject: [PATCH 4/9] update screenshots --- .../stories/__images__/AcceptModal-base-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-both-oauth-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-oauth-oauth-chromium.png | 4 ++-- .../stories/__images__/BaseFormView-ouath-basic-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-base-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-create-mode-chromium.png | 4 ++-- .../__images__/CheckboxGroup-input-page-view-chromium.png | 4 ++-- .../__images__/CheckboxGroup-mixed-with-groups-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-multiline-chromium.png | 4 ++-- .../__images__/CheckboxGroup-required-view-chromium.png | 4 ++-- .../__images__/CheckboxGroup-with-single-group-chromium.png | 4 ++-- .../stories/__images__/ControlWrapper-base-chromium.png | 4 ++-- .../stories/__images__/DeleteModal-base-chromium.png | 4 ++-- .../stories/__images__/DeleteModal-inputs-chromium.png | 4 ++-- .../stories/__images__/DownloadButton-base-chromium.png | 4 ++-- .../stories/__images__/EntityModal-base-chromium.png | 4 ++-- .../stories/__images__/EntityModal-inputs-chromium.png | 4 ++-- .../stories/__images__/EntityPage-base-chromium.png | 4 ++-- .../stories/__images__/EntityPage-inputs-chromium.png | 4 ++-- .../stories/__images__/ErrorBoundary-base-chromium.png | 4 ++-- .../stories/__images__/ErrorModal-base-chromium.png | 4 ++-- .../stories/__images__/FileInputComponent-base-chromium.png | 4 ++-- ...ileInputComponent-encrypted-with-default-name-chromium.png | 4 ++-- .../FileInputComponent-with-default-name-chromium.png | 4 ++-- .../Group/stories/__images__/Group-base-chromium.png | 4 ++-- .../Group/stories/__images__/Group-expandable-chromium.png | 4 ++-- .../stories/__images__/HelpLinkComponent-base-chromium.png | 4 ++-- .../stories/__images__/MarkdownMessage-base-chromium.png | 4 ++-- .../MenuInput/stories/__images__/MenuInput-base-chromium.png | 4 ++-- .../stories/__images__/MenuInput-with-sub-menu-chromium.png | 4 ++-- .../__images__/MultiInputComponent-all-props-chromium.png | 4 ++-- .../stories/__images__/MultiInputComponent-base-chromium.png | 4 ++-- .../__images__/MultiInputComponent-endpoint-api-chromium.png | 4 ++-- .../stories/__images__/PlaceholderComponent-base-chromium.png | 4 ++-- .../stories/__images__/RadioComponent-base-chromium.png | 4 ++-- .../SingleInputComponent-accept-any-input-chromium.png | 4 ++-- ...leInputComponent-allow-deny-list-from-backend-chromium.png | 4 ++-- .../__images__/SingleInputComponent-select-list-chromium.png | 4 ++-- .../stories/__images__/SubDescription-base-chromium.png | 4 ++-- .../stories/__images__/TableWrapper-ouath-basic-chromium.png | 4 ++-- .../ConfigurationPage-configuration-page-view-chromium.png | 4 ++-- .../__images__/DashboardPage-dashboard-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-page-expanded-row-chromium.png | 4 ++-- .../__images__/InputPage-input-page-view-add-chromium.png | 4 ++-- .../stories/__images__/InputPage-input-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-tab-view-add-chromium.png | 4 ++-- ...obalConfigPlayground-global-config-playground-chromium.png | 4 ++-- 47 files changed, 94 insertions(+), 94 deletions(-) diff --git a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png index f33eb8b6e..829ac1e2c 100644 --- a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png +++ b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb678ceca7aabaaec25704e1370f8a9fe1d143e74a50753be7a217aae06d8f79 -size 15825 +oid sha256:a336f9a138228be8514412eb1a7dd91f0195937432405990abfe62c08c86e37d +size 16168 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png index 2c7c0ea03..efdd66f37 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-both-oauth-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0d57ea3c23b0bef7edd03939349cbadeefe87ac01fca540ad5f7645ee2ed3e8a -size 29589 +oid sha256:3f136e6822bccfb0351eae671d1c4e89ac9b0070f7095d0e9bcd6988eb9c7699 +size 31173 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png index 8d89fa1b6..bef678c9a 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-oauth-oauth-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d51f70cb960cdf8c14233f9cd8272931aae7886e463c09a8b6668ba8c292c860 -size 42721 +oid sha256:6a5530efff9a39297d24d18887a7099ae14b8428aef261ecffc6300c925560d2 +size 44888 diff --git a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png index 7481f88f3..3ce1e412a 100644 --- a/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png +++ b/ui/src/components/BaseFormView/stories/__images__/BaseFormView-ouath-basic-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2f9f69ce12d2e1149c37eede319e6640506c2f2a5c36738874352a8c2bd2cd9c -size 25784 +oid sha256:23a31401d799e69c31fbae3b5d460c171c2746ee6bdbebdc73fbdd1e4b72ac34 +size 27208 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png index 309bd6a0e..f91320ed7 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:aa1ba903b2f244b4eef71791137bf8069c80eb7e8df5a86b09444abe9d26abea -size 16271 +oid sha256:5925abac7c0eeca3250d1b4bb97213e15db4f7bd0bf1893242d19e873fc3a7b4 +size 16993 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png index 728e98dcf..c1c4c1ef1 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2680562dfc2b43a68f77ea9af0cc5b6ed0dedca754f05dcfd7ec37757968302f -size 13205 +oid sha256:b0ac2633330a46325e5fe1b9c9f4d694df7871109506590fdc59200fd05eaab6 +size 13642 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png index c138bf75b..da3599003 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4ad6aa336b99ee6b0a5466feb443c7a25bfedf73db6a0cbf42f3b6ab52fdd66a -size 34452 +oid sha256:38674bfbdc583a3c28bef5604e00cb74488bb83e8d419ede5f14dd97e1df5463 +size 35397 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png index a78c08ac8..78dba2025 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-mixed-with-groups-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a00b0a73c2717429294b3b383933d4721af6daa43bc1d8bffc9dc69816b162c5 -size 23336 +oid sha256:7699985e66e315c507cdc7f00426a1e9d6d81fb9f926071b2d5ca6b594c1d5d9 +size 24630 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png index f73c96c53..c32934f6a 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0d02fce78ce6ff2e1ea2a39ee242d6e3eec9554cf363d1352084149a16f7e9b3 -size 20960 +oid sha256:07f6deaec3ad944292a1a1164dcacb8a0e4ea6aedf4c0d4a6af5913c66a8fb79 +size 22426 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png index 898bb8597..fa8b99485 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d76af67b2eb2d1f0cd1d9b4aecf93e450dd5214d14c6bc47c4032cd18e43c573 -size 40558 +oid sha256:473c22b7b6541839dc787f789559d805b2eec23feabb1f1e7d05370175a533a8 +size 42188 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png index 834b73743..e928ae6dc 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-with-single-group-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:585b056c9ba9abd1ab3c7df6ee96479b49c1f5aa5cf30ecd7ac82fbc1f068c1c -size 13122 +oid sha256:c1cff901be8b049e45f8245f15b53b870c6923ea57502e428aa196258036df49 +size 13597 diff --git a/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png b/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png index 5e8e39b31..3c510e1e8 100644 --- a/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png +++ b/ui/src/components/ControlWrapper/stories/__images__/ControlWrapper-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dc09f9fa0685c357ddcb83187e830adc7c556b6d4b97e98a80c8b86378909461 -size 16330 +oid sha256:c216dc3fb057054798ac053d8349c861901a399fb462b1b4f3966ae776b9339b +size 17144 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png index 6d6f6218a..f3099d03b 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2be45fb23b6427ef8f49c407773fcd827684092fe702ec5139a8c84a052886c6 -size 21540 +oid sha256:8e6dac04031322624c5e4fd843505fc734af840842332386d1d24fc49c2c4097 +size 22865 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png index 7abe9a91a..4caa787cb 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:54652616281a37cd5c7a357ca1ed9dfde156613c451b9a93842d4b38847ce463 -size 15889 +oid sha256:1e8682223ae091df80afde6220338bf502a6850f25b4c7eb4f4241d941b7abac +size 16365 diff --git a/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png b/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png index 8efe7eb4c..84ec7b190 100644 --- a/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png +++ b/ui/src/components/DownloadButton/stories/__images__/DownloadButton-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:86c3a5ea9a168f03903a1598824e95457d352c12f6299473ccb23e485d4f70b2 -size 5273 +oid sha256:9e9c700686f86996d1e5a045ff85020f3fe74a9cd38aba3daeb535edfa5b9975 +size 5350 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png index 913799dda..e02f9955c 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d3ca2caa0d2aadc6c365f945527ecf55d5049aa574137e7cf8cdc9d334049282 -size 21760 +oid sha256:25348f1ab0b290da6efb1f9bd550bb003150f980b4f922382ea1d67e934cb80e +size 22571 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png index 4245ac3c8..9046aa812 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:411c0a64aec50eb9162f40a504e792b7aaf9e7dc12bb11b7bc15286dae2f7741 -size 27508 +oid sha256:504ca5b886ee8a98501b73405c2b6b30416844d96817d92888e348cea3d04e73 +size 28532 diff --git a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png index afa11306a..2b8d2c05b 100644 --- a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png +++ b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f1a02b87e3c93284b1e935812ee0bbebe923e229ce9ceb2267ebb51885dd41e4 -size 22515 +oid sha256:c8045e284dcdd4ec43edda0fb857f86675f56a411a7881b6ea025e13b1b5e33e +size 23445 diff --git a/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png b/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png index ffcebbacf..15351fad0 100644 --- a/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png +++ b/ui/src/components/EntityPage/stories/__images__/EntityPage-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e2daa11543457c1a38758b9492c60bad0ff7a8f2dd72241c2ceaa94ae0cc3769 -size 27194 +oid sha256:8b00f8c345b476e49e1fa4b84359bc34f95fa956d7d545b2bc2033bb3af3d54b +size 28254 diff --git a/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png b/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png index 83b0d2db9..09f91ec34 100644 --- a/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png +++ b/ui/src/components/ErrorBoundary/stories/__images__/ErrorBoundary-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:7ba5f992968fea84827106a82772f4f9ac93caaeed92ad48fdd89e64cefbe500 -size 12710 +oid sha256:b99352a6e8b6de186ab2748bfa51090c36db5b2252340a8475ef4abdc733d594 +size 13128 diff --git a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png index 6c2ba999a..c6722fb28 100644 --- a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png +++ b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:cdaecce434f5ad644e2560532bcf3e167323e63721b34c47f4c336085bf05fc5 -size 11571 +oid sha256:79918565c1a82f8f9fcdbbe345a2e8aa8820191b91322259510fcce133f60556 +size 11823 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png index 963e1614e..1629f97cf 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:f77db7c515972f0811be9b48627d0672ce09c9893593794aa7b7b751d6591b07 -size 8033 +oid sha256:fe011fd0b7b6a8538c9b9266837fc2fd2d8b2b25e6d535538988304dfd52140f +size 8388 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png index c8c517463..d896a344c 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-encrypted-with-default-name-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e2e5bb7dc88e818a6330b4fce19c2d1b3df5ef30fd587fbfea21d5548c4d018f -size 12482 +oid sha256:3a35017793237885e55d1c82930b4c47efbbd3cc14fd751e320647278e4160f8 +size 13098 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png index e87a98acf..62fb5365b 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bbb371b7a94a5d0f758454f4d1296cdcd7e3088da48efdeeaa0583ec2ee2bccb -size 10586 +oid sha256:0b2e78f77c7118919fb288faf10493f4b03393c3a17e4e8d6b8446504ed6432b +size 11002 diff --git a/ui/src/components/Group/stories/__images__/Group-base-chromium.png b/ui/src/components/Group/stories/__images__/Group-base-chromium.png index 0be6da412..e96178ba8 100644 --- a/ui/src/components/Group/stories/__images__/Group-base-chromium.png +++ b/ui/src/components/Group/stories/__images__/Group-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:075ae64e82bcc4512e0f0937ce0ba6c2e52a79a68b00d275d9bcd65448cead72 -size 8895 +oid sha256:14af50ceb9760f7b66fd7e6b0ba87a5378acb17c0014b99734265695c3da42b3 +size 9336 diff --git a/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png b/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png index 128ee56f4..992ba4129 100644 --- a/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png +++ b/ui/src/components/Group/stories/__images__/Group-expandable-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d1acf1fb9e0f46d6b3405f61dcaf45cdb8d5dd7be3ada47220e34e88245c8290 -size 8471 +oid sha256:573f9fe8e97b021dafa0b1f79adcedb9161be15ead2d311b0e582ef38dee5dee +size 8942 diff --git a/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png b/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png index 37db5ab34..bd68383df 100644 --- a/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png +++ b/ui/src/components/HelpLinkComponent/stories/__images__/HelpLinkComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8ad3c989d8ead512fd3daa6fb0193b75663de13d8f4dc1e6bc078fe6349de028 -size 5400 +oid sha256:bdf734626357c127f64d0a3aaa40ae939b40b4ffe750f9cea0ac0a398372652f +size 5490 diff --git a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png index 6d8f11bfc..fc6d92a0b 100644 --- a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png +++ b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d64bd81f64d395fb3b6dc3dfc5d265bae0d4a75ec1257a05c06dba517e1b1851 -size 1437 +oid sha256:9665cdb4e21c526baf669662a0e80b32a3fd9e2049c54567a0e6f08916b01aa5 +size 1483 diff --git a/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png b/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png index d9df1c57a..050717726 100644 --- a/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png +++ b/ui/src/components/MenuInput/stories/__images__/MenuInput-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4557ef290d4fa43312519e79a78c19fb2879f62f799d9b465faa45099d1171a3 -size 5932 +oid sha256:9a75a1f75e19664a958350775ff50ea4d8cbeb1980aafaaba2d0f1c41c105779 +size 6006 diff --git a/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png b/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png index d9df1c57a..050717726 100644 --- a/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png +++ b/ui/src/components/MenuInput/stories/__images__/MenuInput-with-sub-menu-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:4557ef290d4fa43312519e79a78c19fb2879f62f799d9b465faa45099d1171a3 -size 5932 +oid sha256:9a75a1f75e19664a958350775ff50ea4d8cbeb1980aafaaba2d0f1c41c105779 +size 6006 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png index a73149321..bfe572d9a 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-all-props-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdf1f9b4b905d2d3a276ce9e0e25bc3f0928e3929c0a9085aeefa40d2f974fc0 -size 4410 +oid sha256:43b31c53bc97909f7839c5e3850b8637b3dcef6e7609a99b722edabe54bd9b6e +size 4494 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png index a73149321..bfe572d9a 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bdf1f9b4b905d2d3a276ce9e0e25bc3f0928e3929c0a9085aeefa40d2f974fc0 -size 4410 +oid sha256:43b31c53bc97909f7839c5e3850b8637b3dcef6e7609a99b722edabe54bd9b6e +size 4494 diff --git a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png index fa9ea7a97..ef8e7bc39 100644 --- a/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png +++ b/ui/src/components/MultiInputComponent/stories/__images__/MultiInputComponent-endpoint-api-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:19937b12227641701bf54ecded7021c27a51319e2d979e6d3c6253d2e28c9754 -size 4410 +oid sha256:ede2226dd7b8cb2eae603512060a9343c7a33b15f2f93ef2126dbee197c112c1 +size 4494 diff --git a/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png b/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png index 98c3ad468..77c0dafcc 100644 --- a/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png +++ b/ui/src/components/PlaceholderComponent/stories/__images__/PlaceholderComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:2823cdf2a6f6d94a6e569f3766bac3b31149db9115a9cc7eaee06b61b07374bc -size 4701 +oid sha256:c81ff53f649988b87ab58c8a18c82657c14311bd68d3f48a9e673dfcb81313d9 +size 4872 diff --git a/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png b/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png index 3f623c5f4..d0712db89 100644 --- a/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png +++ b/ui/src/components/RadioComponent/stories/__images__/RadioComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:6e44375de1b0e8cb076b4a4488f0d7789b2bbe0af24789387fe8440f9f776210 -size 5932 +oid sha256:747ee92b01175dc4af79b063d2e377d6329b1ae9d198108a7385cd2d1019a484 +size 6094 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png index 4d2b71edc..401b2c00b 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-accept-any-input-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ca4a7b129c4eccf7444e0510ada0ecce566cb04f213799dfc67020b60e7256b1 -size 4535 +oid sha256:ec8e1e95fac3fc5f8bdc090c6ecaa449c01227b53a96acc91e114c2995a306f6 +size 4606 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png index 4d2b71edc..401b2c00b 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-allow-deny-list-from-backend-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:ca4a7b129c4eccf7444e0510ada0ecce566cb04f213799dfc67020b60e7256b1 -size 4535 +oid sha256:ec8e1e95fac3fc5f8bdc090c6ecaa449c01227b53a96acc91e114c2995a306f6 +size 4606 diff --git a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png index 3320f9f1f..306fd1a00 100644 --- a/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png +++ b/ui/src/components/SingleInputComponent/stories/__images__/SingleInputComponent-select-list-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:58597a3121696b8e8e62aa8cff59f314204e640f3ee81266ffd4e71634a25111 -size 4535 +oid sha256:ec2385e021d2b5c59666406ce756a8967f0dd34e056cdb6c51f864fc10ab77a0 +size 4606 diff --git a/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png b/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png index 5396fc3ee..c3f6ab2d2 100644 --- a/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png +++ b/ui/src/components/SubDescription/stories/__images__/SubDescription-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:e791b6f762cd7db73a5bfea37ef11d5f830bf2929f1ab2badd27fbbe44d70e16 -size 35285 +oid sha256:864e63a6dd8d49fbf063ce72abcb93c21e528f778c99e5574b1c63bf04f20f0e +size 37365 diff --git a/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png b/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png index 871c2b7ae..0ce27c13f 100644 --- a/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png +++ b/ui/src/components/table/stories/__images__/TableWrapper-ouath-basic-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:dd3ab6ecfca701dce02b1a1c38bb23dca834d3c7926fe1d3fd79194511635d97 -size 24972 +oid sha256:be0a6fe4a2d07cfdf32ba7724158dff463ac459a327e8cc29c18543796ba5cab +size 25440 diff --git a/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png b/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png index 3a16bdec9..046f648b0 100644 --- a/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png +++ b/ui/src/pages/Configuration/stories/__images__/ConfigurationPage-configuration-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d213a73d5dd1768ff7d66bc062650b83a194cc22787591506fca40fc1ef66c5e -size 56020 +oid sha256:8d4895cbb18b7cbc661c4935325f344549f1949ea7c01a7d3f90be5547f984ce +size 59002 diff --git a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png index 33616af17..44ced07e0 100644 --- a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png +++ b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9bc77374f54d30126f91e549935645420aa3e8620cc71531325fda4ff096d095 -size 79758 +oid sha256:488667f088c64457eec85fba6a852ced1267525c3dfc42acb8fc5cacf16804ca +size 83063 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png index 8938dbd69..53e978ebb 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:bc79a4c99df71876e77cb71e7d9e4e2bbcb61b74c8ecaf95c681ef4c026a687f -size 46100 +oid sha256:d6c72ef2f1e1f9ac80700511eefb21e2136cf0788e0edb0abc526137a2f8fb30 +size 47591 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png index a4e2ca393..6776ed0e0 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fb54998598b3aa242cfe62b4cc4a138c9f4717e210abf1f28311bfc9d5670749 -size 70930 +oid sha256:eaa4a74246ac18335ca7c1cd9fe34bfdd23061084507882849b43acac19f95ea +size 72701 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png index a5fe467f5..f7e621b73 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c8a29a7a2bc67e9a7f089d7a15a6326928f32c34c8ba4e594f79b4db5cf52968 -size 39328 +oid sha256:fe9f0ff3d23df9eb9926ae214a1c5f595ec1ee5dfa136b4d7004b409face2bcc +size 40226 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png index 3416ddc40..a985b212f 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c43edb70928ccabc2e2ac5ce07c6c564be79620a4c9e881acaa517aaf1fcec2d -size 60740 +oid sha256:73aff7aadd0d3d1db81a34e91a48c168fa587b57459e1b8c6571ae619a948362 +size 63488 diff --git a/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png b/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png index 563e257c4..9be0aae12 100644 --- a/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png +++ b/ui/src/pages/stories/__images__/GlobalConfigPlayground-global-config-playground-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:da13e2722849499cdd7c7c79ad3bebcfd3f61177e4ea1b4688daec69cdb1d6ef -size 59082 +oid sha256:68ddd13b7feccb5aac38c0215dc12645198341bed1f4793bcd8009913476284b +size 62321 From d20954e182c99ffeb56620c01320677b330bb265 Mon Sep 17 00:00:00 2001 From: sgoral Date: Mon, 14 Oct 2024 16:48:28 +0200 Subject: [PATCH 5/9] test: change subprocess_run --- splunk_add_on_ucc_framework/install_python_libraries.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/splunk_add_on_ucc_framework/install_python_libraries.py b/splunk_add_on_ucc_framework/install_python_libraries.py index 3904b682d..6fdf652b0 100644 --- a/splunk_add_on_ucc_framework/install_python_libraries.py +++ b/splunk_add_on_ucc_framework/install_python_libraries.py @@ -115,6 +115,8 @@ def _pip_is_lib_installed( my_env["PYTHONPATH"] = target if allow_higher_version: result = _subprocess_run(command=cmd, env=my_env) + if result.returncode != 0: + return False result_version = result.stdout.decode("utf-8").split("Version:")[1].strip() return Version(result_version) >= Version(version) else: From a41fd3ed1b2ba9a55e8d77c060372d4b5b370626 Mon Sep 17 00:00:00 2001 From: sgoral Date: Mon, 14 Oct 2024 16:59:00 +0200 Subject: [PATCH 6/9] test: add unit test for wrong version --- tests/unit/test_install_python_libraries.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/tests/unit/test_install_python_libraries.py b/tests/unit/test_install_python_libraries.py index 9831af107..0a709fff9 100644 --- a/tests/unit/test_install_python_libraries.py +++ b/tests/unit/test_install_python_libraries.py @@ -200,6 +200,22 @@ def test_install_libraries_when_no_splunktaucclib_is_present_but_has_ui(tmp_path ) +def test_install_libraries_when_wrong_splunktaucclib_is_present_but_has_ui(tmp_path): + tmp_ucc_lib_target = tmp_path / "ucc-lib-target" + tmp_lib_path = tmp_path / "lib" + tmp_lib_path.mkdir() + tmp_lib_reqs_file = tmp_lib_path / "requirements.txt" + tmp_lib_reqs_file.write_text("splunktaucclib==6.3\n") + + with pytest.raises(SplunktaucclibNotFound): + install_python_libraries( + str(tmp_path), + str(tmp_ucc_lib_target), + python_binary_name="python3", + includes_ui=True, + ) + + def test_remove_package_from_installed_path(tmp_path): tmp_lib_path = tmp_path / "lib" tmp_lib_path.mkdir() From 2fc1cae0d65929154f003123477796b118efefcc Mon Sep 17 00:00:00 2001 From: sgoral Date: Mon, 14 Oct 2024 17:24:03 +0200 Subject: [PATCH 7/9] test: fix tests --- tests/unit/test_install_python_libraries.py | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/tests/unit/test_install_python_libraries.py b/tests/unit/test_install_python_libraries.py index 0a709fff9..a6d27473d 100644 --- a/tests/unit/test_install_python_libraries.py +++ b/tests/unit/test_install_python_libraries.py @@ -129,9 +129,7 @@ def test_install_libraries_when_subprocess_returns_non_zero_codes( ) -@mock.patch("subprocess.call", autospec=True) -def test_install_python_libraries(mock_subprocess_call, tmp_path): - mock_subprocess_call.return_value = 0 +def test_install_python_libraries(tmp_path): tmp_ucc_lib_target = tmp_path / "ucc-lib-target" tmp_ucc_lib_target.mkdir() tmp_lib_path = tmp_path / "lib" From fd052450811776927b592e3ff3d938defdb0a944 Mon Sep 17 00:00:00 2001 From: sgoral Date: Tue, 15 Oct 2024 13:30:51 +0200 Subject: [PATCH 8/9] chore: revert bot commits --- .../stories/__images__/AcceptModal-base-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-base-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-create-mode-chromium.png | 4 ++-- .../__images__/CheckboxGroup-input-page-view-chromium.png | 4 ++-- .../stories/__images__/CheckboxGroup-multiline-chromium.png | 4 ++-- .../__images__/CheckboxGroup-required-view-chromium.png | 2 +- .../stories/__images__/DeleteModal-base-chromium.png | 2 +- .../stories/__images__/DeleteModal-inputs-chromium.png | 4 ++-- .../stories/__images__/EntityModal-base-chromium.png | 4 ++-- .../stories/__images__/EntityModal-inputs-chromium.png | 2 +- .../stories/__images__/EntityPage-base-chromium.png | 4 ++-- .../stories/__images__/ErrorModal-base-chromium.png | 2 +- .../stories/__images__/FileInputComponent-base-chromium.png | 4 ++-- .../FileInputComponent-with-default-name-chromium.png | 4 ++-- .../stories/__images__/MarkdownMessage-base-chromium.png | 4 ++-- .../__images__/DashboardPage-dashboard-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-page-expanded-row-chromium.png | 4 ++-- .../__images__/InputPage-input-page-view-add-chromium.png | 4 ++-- .../stories/__images__/InputPage-input-page-view-chromium.png | 4 ++-- .../__images__/InputPage-input-tab-view-add-chromium.png | 4 ++-- 20 files changed, 36 insertions(+), 36 deletions(-) diff --git a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png index 829ac1e2c..e3523ce17 100644 --- a/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png +++ b/ui/src/components/AcceptModal/stories/__images__/AcceptModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:a336f9a138228be8514412eb1a7dd91f0195937432405990abfe62c08c86e37d -size 16168 +oid sha256:5b90c15d31812b868553f5569cf1c3e4751e0fcf228d6f06635f3fa645be2e9e +size 16164 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png index f91320ed7..592edf7a6 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:5925abac7c0eeca3250d1b4bb97213e15db4f7bd0bf1893242d19e873fc3a7b4 -size 16993 +oid sha256:5f622a709b2e0c9cb0676831796ed6f4fe11824bfc62a285d8630f3e57deb2a9 +size 16998 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png index c1c4c1ef1..f33ae6e42 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-create-mode-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:b0ac2633330a46325e5fe1b9c9f4d694df7871109506590fdc59200fd05eaab6 -size 13642 +oid sha256:5b352ab6169c33388a243bb7192e140b6a675ea779b371169e14747e7ba47c34 +size 13644 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png index da3599003..8c9d0ffff 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:38674bfbdc583a3c28bef5604e00cb74488bb83e8d419ede5f14dd97e1df5463 -size 35397 +oid sha256:ba82abe77bd2a19627d3ca369ea967d124df0587a0c4975e471a567863a1fc11 +size 35401 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png index c32934f6a..146fcf304 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-multiline-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:07f6deaec3ad944292a1a1164dcacb8a0e4ea6aedf4c0d4a6af5913c66a8fb79 -size 22426 +oid sha256:d1eb78f2d8a89f8562ed6ea4cc51815dca7c7d502740d49301dee847a7b596a3 +size 22434 diff --git a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png index fa8b99485..29fc7a258 100644 --- a/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png +++ b/ui/src/components/CheckboxGroup/stories/__images__/CheckboxGroup-required-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:473c22b7b6541839dc787f789559d805b2eec23feabb1f1e7d05370175a533a8 +oid sha256:75dcf61492b5842f47d360c4a8e40641c9f84a4ad3a147d69c6ea4abf89f1ef8 size 42188 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png index f3099d03b..a0acd3c45 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:8e6dac04031322624c5e4fd843505fc734af840842332386d1d24fc49c2c4097 +oid sha256:470412651d90dc22b69b3abb4cc571cb2cfe2f405916953e855eb2fc522c8762 size 22865 diff --git a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png index 4caa787cb..44f83b10e 100644 --- a/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png +++ b/ui/src/components/DeleteModal/stories/__images__/DeleteModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:1e8682223ae091df80afde6220338bf502a6850f25b4c7eb4f4241d941b7abac -size 16365 +oid sha256:32ae042f3b360b1559846060d4f9e6ee419786a52c5ca5cdd26419fa30cd0fff +size 16369 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png index e02f9955c..489dabd78 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:25348f1ab0b290da6efb1f9bd550bb003150f980b4f922382ea1d67e934cb80e -size 22571 +oid sha256:471744a25ce5b359263b7f9aa53db461a77590f7422492a5e2287cd6758a8e3b +size 22561 diff --git a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png index 9046aa812..82b592cf0 100644 --- a/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png +++ b/ui/src/components/EntityModal/stories/__images__/EntityModal-inputs-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:504ca5b886ee8a98501b73405c2b6b30416844d96817d92888e348cea3d04e73 +oid sha256:56be9cafa0bcad4cb68c9a4c8135d93948637e6a72be601b0e2f8100effa29ed size 28532 diff --git a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png index 2b8d2c05b..4d9e2ee1e 100644 --- a/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png +++ b/ui/src/components/EntityPage/stories/__images__/EntityPage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c8045e284dcdd4ec43edda0fb857f86675f56a411a7881b6ea025e13b1b5e33e -size 23445 +oid sha256:91648fa6f8ac5d712924f25cbf62d544b2364fcb69ed8baf53ae5392decf8503 +size 23434 diff --git a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png index c6722fb28..a2e7cf9a1 100644 --- a/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png +++ b/ui/src/components/ErrorModal/stories/__images__/ErrorModal-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:79918565c1a82f8f9fcdbbe345a2e8aa8820191b91322259510fcce133f60556 +oid sha256:68c875054edea5fa11b31b2a0779afbf6fd8f9944a7a3c6d699a0ce880842cf2 size 11823 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png index 1629f97cf..47baecc7d 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe011fd0b7b6a8538c9b9266837fc2fd2d8b2b25e6d535538988304dfd52140f -size 8388 +oid sha256:0bdbcdfacb6100ee33aada803d9b85efc6cec76df6cb6ed0ea15fb61478c9dde +size 8379 diff --git a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png index 62fb5365b..227dade1f 100644 --- a/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png +++ b/ui/src/components/FileInputComponent/stories/__images__/FileInputComponent-with-default-name-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:0b2e78f77c7118919fb288faf10493f4b03393c3a17e4e8d6b8446504ed6432b -size 11002 +oid sha256:9fbff82c2757375c53fc35dcb7110a30cddc33b95222db356885c089a58aa104 +size 10993 diff --git a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png index fc6d92a0b..0261ee8f3 100644 --- a/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png +++ b/ui/src/components/MarkdownMessage/stories/__images__/MarkdownMessage-base-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:9665cdb4e21c526baf669662a0e80b32a3fd9e2049c54567a0e6f08916b01aa5 -size 1483 +oid sha256:9a3d5ccce46345708f0c487044dca718a9f203471bf28cf48a436c6abef3286c +size 1607 diff --git a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png index 44ced07e0..aef1ca1ac 100644 --- a/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png +++ b/ui/src/pages/Dashboard/stories/__images__/DashboardPage-dashboard-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:488667f088c64457eec85fba6a852ced1267525c3dfc42acb8fc5cacf16804ca -size 83063 +oid sha256:17c26b26a1e89743412d372462e05c4df6c4132583e6925531851ca44c789e8b +size 83057 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png index 53e978ebb..7c8be001e 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-expanded-row-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:d6c72ef2f1e1f9ac80700511eefb21e2136cf0788e0edb0abc526137a2f8fb30 -size 47591 +oid sha256:da66686cf67903cc17c782b3e7e34b3b7374de528b273db993f4d0a66f6b4525 +size 47539 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png index 6776ed0e0..8f1188576 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:eaa4a74246ac18335ca7c1cd9fe34bfdd23061084507882849b43acac19f95ea -size 72701 +oid sha256:60afb91e9133f946070c37500495bb20830040b828ee59540c3aa23d1d5e473c +size 72703 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png index f7e621b73..e8edddd23 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-page-view-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:fe9f0ff3d23df9eb9926ae214a1c5f595ec1ee5dfa136b4d7004b409face2bcc -size 40226 +oid sha256:1af6a372d92392853b636aafacf8ef8f1510af947688dc42b5fa7f3dfbb8169b +size 40184 diff --git a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png index a985b212f..073b8da55 100644 --- a/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png +++ b/ui/src/pages/Input/stories/__images__/InputPage-input-tab-view-add-chromium.png @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:73aff7aadd0d3d1db81a34e91a48c168fa587b57459e1b8c6571ae619a948362 -size 63488 +oid sha256:6e7c5bfa0d54800282eb59294c040de3b7a7d1fe4d4be35ca24740acdcd89ece +size 63504 From 54864c7c8817bca03681632ad2d12f201d5c6067 Mon Sep 17 00:00:00 2001 From: sgoral Date: Wed, 16 Oct 2024 13:03:25 +0200 Subject: [PATCH 9/9] feat: refactor of _subprocess_call fun, add tests, distinguish splunktaucclib errors --- poetry.lock | 3 +- pyproject.toml | 1 + .../install_python_libraries.py | 72 ++++++----- tests/unit/test_install_python_libraries.py | 117 ++++++++++++------ 4 files changed, 118 insertions(+), 75 deletions(-) diff --git a/poetry.lock b/poetry.lock index cec4a2cdf..e42aedc6f 100644 --- a/poetry.lock +++ b/poetry.lock @@ -1358,7 +1358,6 @@ files = [ {file = "PyYAML-6.0.1-cp311-cp311-win_amd64.whl", hash = "sha256:bf07ee2fef7014951eeb99f56f39c9bb4af143d8aa3c21b1677805985307da34"}, {file = "PyYAML-6.0.1-cp312-cp312-macosx_10_9_x86_64.whl", hash = "sha256:855fb52b0dc35af121542a76b9a84f8d1cd886ea97c84703eaa6d88e37a2ad28"}, {file = "PyYAML-6.0.1-cp312-cp312-macosx_11_0_arm64.whl", hash = "sha256:40df9b996c2b73138957fe23a16a4f0ba614f4c0efce1e9406a184b6d07fa3a9"}, - {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl", hash = "sha256:a08c6f0fe150303c1c6b71ebcd7213c2858041a7e01975da3a99aed1e7a378ef"}, {file = "PyYAML-6.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl", hash = "sha256:6c22bec3fbe2524cde73d7ada88f6566758a8f7227bfbf93a408a9d86bcc12a0"}, {file = "PyYAML-6.0.1-cp312-cp312-musllinux_1_1_x86_64.whl", hash = "sha256:8d4e9c88387b0f5c7d5f281e55304de64cf7f9c0021a3525bd3b1c542da3b0e4"}, {file = "PyYAML-6.0.1-cp312-cp312-win32.whl", hash = "sha256:d483d2cdf104e7c9fa60c544d92981f12ad66a457afae824d146093b8c294c54"}, @@ -1754,4 +1753,4 @@ testing = ["big-O", "flake8 (<5)", "jaraco.functools", "jaraco.itertools", "more [metadata] lock-version = "2.0" python-versions = "^3.7" -content-hash = "71a9dc95114ab50cc2a05784f48b443d2655789a68152093d8a89f8cffc42654" +content-hash = "5ce229450418d58e52d0d6dc05f04b0ef7e36b0ef1f71c4ae37f4cb73659347d" diff --git a/pyproject.toml b/pyproject.toml index c5c8ced60..aa1f67dc9 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -47,6 +47,7 @@ jsonschema = "^4.4.0" PyYAML = "^6.0" defusedxml = "^0.7.1" colorama = "^0.4.6" +packaging = "24.0" [tool.poetry.group.dev.dependencies] mkdocs = "^1.4.2" diff --git a/splunk_add_on_ucc_framework/install_python_libraries.py b/splunk_add_on_ucc_framework/install_python_libraries.py index 6fdf652b0..ea8e8d478 100644 --- a/splunk_add_on_ucc_framework/install_python_libraries.py +++ b/splunk_add_on_ucc_framework/install_python_libraries.py @@ -32,6 +32,10 @@ class SplunktaucclibNotFound(Exception): pass +class WrongSplunktaucclibVersion(Exception): + pass + + class CouldNotInstallRequirements(Exception): pass @@ -40,40 +44,25 @@ class InvalidArguments(Exception): pass -def _subprocess_call( +def _subprocess_run( command: str, command_desc: Optional[str] = None, env: Optional[Dict[str, str]] = None, -) -> int: +) -> "subprocess.CompletedProcess[bytes]": command_desc = command_desc or command try: logger.info(f"Executing: {command}") - return_code = subprocess.call(command, shell=True, env=env) + process_result = subprocess.run( + command, shell=True, env=env, capture_output=True + ) + return_code = process_result.returncode if return_code < 0: logger.error( f"Child ({command_desc}) was terminated by signal {-return_code}" ) if return_code > 0: logger.error(f"Command ({command_desc}) returned {return_code} status code") - return return_code - except OSError as e: - logger.error(f"Execution ({command_desc}) failed due to {e}") - raise e - - -def _subprocess_run( - command: str, - command_desc: Optional[str] = None, - env: Optional[Dict[str, str]] = None, -) -> "subprocess.CompletedProcess[bytes]": - command_desc = command_desc or command - try: - logger.info(f"Executing: {command}") - process_result = subprocess.run( - command, shell=True, env=env, capture_output=True - ) return process_result - except OSError as e: logger.error(f"Execution ({command_desc}) failed due to {e}") raise e @@ -82,7 +71,7 @@ def _subprocess_run( def _pip_install(installer: str, command: str, command_desc: str) -> None: cmd = f"{installer} -m pip install {command}" try: - return_code = _subprocess_call(command=cmd, command_desc=command_desc) + return_code = _subprocess_run(command=cmd, command_desc=command_desc).returncode if return_code != 0: raise CouldNotInstallRequirements except OSError as e: @@ -120,7 +109,7 @@ def _pip_is_lib_installed( result_version = result.stdout.decode("utf-8").split("Version:")[1].strip() return Version(result_version) >= Version(version) else: - return_code = _subprocess_call(command=cmd, env=my_env) + return_code = _subprocess_run(command=cmd, env=my_env).returncode return return_code == 0 except OSError as e: raise CouldNotInstallRequirements from e @@ -135,6 +124,30 @@ def _check_ucc_library_in_requirements_file(path_to_requirements: str) -> bool: return False +def _check_libraries_required_for_ui( + python_binary_name: str, ucc_lib_target: str, path_to_requirements_file: str +) -> None: + if not _pip_is_lib_installed( + installer=python_binary_name, + target=ucc_lib_target, + libname="splunktaucclib", + ): + raise SplunktaucclibNotFound( + f"This add-on has an UI, so the splunktaucclib is required but not found in " + f"{path_to_requirements_file}. Please add it there and make sure it is at least version 6.4." + ) + if not _pip_is_lib_installed( + installer=python_binary_name, + target=ucc_lib_target, + libname="splunktaucclib", + version="6.4", + allow_higher_version=True, + ): + raise WrongSplunktaucclibVersion( + "Splunktaucclib found but has the wrong version. Please make sure it is at least version 6.4." + ) + + def install_python_libraries( source_path: str, ucc_lib_target: str, @@ -156,16 +169,9 @@ def install_python_libraries( pip_version=pip_version, pip_legacy_resolver=pip_legacy_resolver, ) - if includes_ui and not _pip_is_lib_installed( - installer=python_binary_name, - target=ucc_lib_target, - libname="splunktaucclib", - version="6.4", - allow_higher_version=True, - ): - raise SplunktaucclibNotFound( - f"splunktaucclib is not found in {path_to_requirements_file} or has invalid version. " - f"Please add it there and check if it is at least version 6.4, because this add-on has UI." + if includes_ui: + _check_libraries_required_for_ui( + python_binary_name, ucc_lib_target, path_to_requirements_file ) cleanup_libraries = install_os_dependent_libraries( diff --git a/tests/unit/test_install_python_libraries.py b/tests/unit/test_install_python_libraries.py index a6d27473d..6581a28a9 100644 --- a/tests/unit/test_install_python_libraries.py +++ b/tests/unit/test_install_python_libraries.py @@ -16,11 +16,19 @@ remove_execute_bit, remove_packages, validate_conflicting_paths, + WrongSplunktaucclibVersion, + InvalidArguments, + _pip_is_lib_installed, ) from splunk_add_on_ucc_framework import global_config as gc +class MockSubprocessResult: + def __init__(self, returncode): + self.returncode = returncode + + @pytest.mark.parametrize( "requirements_content,expected_result", [ @@ -71,9 +79,9 @@ def test_check_ucc_library_in_requirements_file( ) -@mock.patch("subprocess.call", autospec=True) -def test_install_libraries(mock_subprocess_call): - mock_subprocess_call.return_value = 0 +@mock.patch("subprocess.run", autospec=True) +def test_install_libraries(mock_subprocess_run): + mock_subprocess_run.return_value = MockSubprocessResult(0) install_libraries( "package/lib/requirements.txt", @@ -87,17 +95,21 @@ def test_install_libraries(mock_subprocess_call): '--target "/path/to/output/addon_name/lib"' ) expected_pip_update_command = "python3 -m pip install --upgrade pip" - mock_subprocess_call.assert_has_calls( + mock_subprocess_run.assert_has_calls( [ - mock.call(expected_pip_update_command, shell=True, env=None), - mock.call(expected_install_command, shell=True, env=None), + mock.call( + expected_pip_update_command, shell=True, env=None, capture_output=True + ), + mock.call( + expected_install_command, shell=True, env=None, capture_output=True + ), ] ) -@mock.patch("subprocess.call", autospec=True) -def test_install_libraries_when_subprocess_raises_os_error(mock_subprocess_call): - mock_subprocess_call.side_effect = OSError +@mock.patch("subprocess.run", autospec=True) +def test_install_libraries_when_subprocess_raises_os_error(mock_subprocess_run): + mock_subprocess_run.side_effect = OSError with pytest.raises(CouldNotInstallRequirements): install_libraries( @@ -116,12 +128,13 @@ def test_install_libraries_when_subprocess_raises_os_error(mock_subprocess_call) (0, -1), ], ) -@mock.patch("subprocess.call", autospec=True) +@mock.patch("subprocess.run", autospec=True) def test_install_libraries_when_subprocess_returns_non_zero_codes( - mock_subprocess_call, + mock_subprocess_run, subprocess_status_codes, ): - mock_subprocess_call.side_effect = subprocess_status_codes + statuses = (MockSubprocessResult(el) for el in subprocess_status_codes) + mock_subprocess_run.side_effect = statuses with pytest.raises(CouldNotInstallRequirements): install_libraries( @@ -162,12 +175,12 @@ def test_install_python_libraries_when_no_requirements_file_found(caplog, tmp_pa assert log_message_expected in caplog.text -@mock.patch("subprocess.call", autospec=True) +@mock.patch("subprocess.run", autospec=True) def test_install_libraries_when_no_splunktaucclib_is_present_but_no_ui( - mock_subprocess_call, + mock_subprocess_run, tmp_path, ): - mock_subprocess_call.return_value = 0 + mock_subprocess_run.return_value = MockSubprocessResult(0) tmp_ucc_lib_target = tmp_path / "ucc-lib-target" tmp_lib_path = tmp_path / "lib" tmp_lib_path.mkdir() @@ -189,13 +202,19 @@ def test_install_libraries_when_no_splunktaucclib_is_present_but_has_ui(tmp_path tmp_lib_reqs_file = tmp_lib_path / "requirements.txt" tmp_lib_reqs_file.write_text("solnlib\nsplunk-sdk\n") - with pytest.raises(SplunktaucclibNotFound): + expected_msg = ( + f"This add-on has an UI, so the splunktaucclib is required but not found in {tmp_lib_reqs_file}. " + f"Please add it there and make sure it is at least version 6.4." + ) + + with pytest.raises(SplunktaucclibNotFound) as exc: install_python_libraries( str(tmp_path), str(tmp_ucc_lib_target), python_binary_name="python3", includes_ui=True, ) + assert expected_msg in str(exc.value) def test_install_libraries_when_wrong_splunktaucclib_is_present_but_has_ui(tmp_path): @@ -205,13 +224,16 @@ def test_install_libraries_when_wrong_splunktaucclib_is_present_but_has_ui(tmp_p tmp_lib_reqs_file = tmp_lib_path / "requirements.txt" tmp_lib_reqs_file.write_text("splunktaucclib==6.3\n") - with pytest.raises(SplunktaucclibNotFound): + expected_msg = "Splunktaucclib found but has the wrong version. Please make sure it is at least version 6.4." + + with pytest.raises(WrongSplunktaucclibVersion) as exc: install_python_libraries( str(tmp_path), str(tmp_ucc_lib_target), python_binary_name="python3", includes_ui=True, ) + assert expected_msg in str(exc.value) def test_remove_package_from_installed_path(tmp_path): @@ -261,15 +283,15 @@ def test_remove_execute_bit(tmp_path): assert os.access(tmp_lib_path_bar_file, os.X_OK) is False -@mock.patch("subprocess.call", autospec=True) +@mock.patch("subprocess.run", autospec=True) @mock.patch( "splunk_add_on_ucc_framework.install_python_libraries.install_libraries", autospec=True, ) def test_install_python_libraries_invalid_os_libraries( - mock_subprocess_call, install_libraries, caplog, tmp_path + install_libraries, mock_subprocess_run, caplog, tmp_path ): - mock_subprocess_call.return_value = 1 + mock_subprocess_run.return_value = MockSubprocessResult(1) install_libraries.return_value = True global_config_path = helpers.get_testdata_file_path( "valid_config_with_invalid_os_libraries.json" @@ -291,14 +313,14 @@ def test_install_python_libraries_invalid_os_libraries( ) -@mock.patch("subprocess.call", autospec=True) +@mock.patch("subprocess.run", autospec=True) @mock.patch( "splunk_add_on_ucc_framework.install_python_libraries.remove_packages", autospec=True, ) def test_install_libraries_valid_os_libraries( mock_remove_packages, - mock_subprocess_call, + mock_subprocess_run, caplog, tmp_path, ): @@ -307,7 +329,7 @@ def test_install_libraries_valid_os_libraries( ) global_config = gc.GlobalConfig(global_config_path) - mock_subprocess_call.return_value = 0 + mock_subprocess_run.return_value = MockSubprocessResult(0) tmp_ucc_lib_target = tmp_path / "ucc-lib-target" tmp_lib_path = tmp_path / "lib" tmp_lib_path.mkdir() @@ -371,14 +393,14 @@ def test_install_libraries_valid_os_libraries( ) -@mock.patch("subprocess.call", autospec=True) +@mock.patch("subprocess.run", autospec=True) @mock.patch( "splunk_add_on_ucc_framework.install_python_libraries.remove_packages", autospec=True, ) def test_install_libraries_version_mismatch( mock_remove_packages, - mock_subprocess_call, + mock_subprocess_run, caplog, tmp_path, ): @@ -397,10 +419,12 @@ def test_install_libraries_version_mismatch( version_mismatch_shell_cmd = ( 'python3 -m pip show --version cryptography | grep "Version: 41.0.5"' ) - mock_subprocess_call.side_effect = ( - lambda command, shell=True, env=None: 1 + mock_subprocess_run.side_effect = ( + lambda command, shell=True, env=None, capture_output=True: MockSubprocessResult( + 1 + ) if command == version_mismatch_shell_cmd and ucc_lib_target == env["PYTHONPATH"] - else 0 + else MockSubprocessResult(0) ) with pytest.raises(CouldNotInstallRequirements): @@ -427,9 +451,9 @@ def test_install_libraries_version_mismatch( mock_remove_packages.assert_not_called() -@mock.patch("subprocess.call", autospec=True) -def test_install_libraries_custom_pip(mock_subprocess_call): - mock_subprocess_call.return_value = 0 +@mock.patch("subprocess.run", autospec=True) +def test_install_libraries_custom_pip(mock_subprocess_run): + mock_subprocess_run.return_value = MockSubprocessResult(0) install_libraries( "package/lib/requirements.txt", @@ -444,17 +468,21 @@ def test_install_libraries_custom_pip(mock_subprocess_call): '--target "/path/to/output/addon_name/lib"' ) expected_pip_update_command = "python3 -m pip install --upgrade pip==21.666.666" - mock_subprocess_call.assert_has_calls( + mock_subprocess_run.assert_has_calls( [ - mock.call(expected_pip_update_command, shell=True, env=None), - mock.call(expected_install_command, shell=True, env=None), + mock.call( + expected_pip_update_command, shell=True, env=None, capture_output=True + ), + mock.call( + expected_install_command, shell=True, env=None, capture_output=True + ), ] ) -@mock.patch("subprocess.call", autospec=True) -def test_install_libraries_legacy_resolver(mock_subprocess_call): - mock_subprocess_call.return_value = 0 +@mock.patch("subprocess.run", autospec=True) +def test_install_libraries_legacy_resolver(mock_subprocess_run): + mock_subprocess_run.return_value = MockSubprocessResult(0) install_libraries( "package/lib/requirements.txt", @@ -469,10 +497,14 @@ def test_install_libraries_legacy_resolver(mock_subprocess_call): '--use-deprecated=legacy-resolver --target "/path/to/output/addon_name/lib"' ) expected_pip_update_command = "python3 -m pip install --upgrade pip" - mock_subprocess_call.assert_has_calls( + mock_subprocess_run.assert_has_calls( [ - mock.call(expected_pip_update_command, shell=True, env=None), - mock.call(expected_install_command, shell=True, env=None), + mock.call( + expected_pip_update_command, shell=True, env=None, capture_output=True + ), + mock.call( + expected_install_command, shell=True, env=None, capture_output=True + ), ] ) @@ -521,3 +553,8 @@ def test_validate_conflicting_paths_with_conflict(os_dependent_library_config, c def test_validate_conflicting_paths_empty_list(): libs: List[OSDependentLibraryConfig] = [] assert validate_conflicting_paths(libs) + + +def test_is_pip_lib_installed_wrong_arguments(): + with pytest.raises(InvalidArguments): + _pip_is_lib_installed("i", "t", "l", allow_higher_version=True)