servicing
Advanced tools
+40
-34
@@ -79,2 +79,8 @@ # This file is automatically @generated by Cargo. | ||
| [[package]] | ||
| name = "atomic-waker" | ||
| version = "1.1.2" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "1505bd5d3d116872e7271a6d4e16d81d0c8570876c8de68093a09ac269d8aac0" | ||
| [[package]] | ||
| name = "autocfg" | ||
@@ -141,5 +147,5 @@ version = "1.3.0" | ||
| name = "cc" | ||
| version = "1.0.97" | ||
| version = "1.0.98" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "099a5357d84c4c61eb35fc8eafa9a79a902c2f76911e5747ced4e032edd8d9b4" | ||
| checksum = "41c270e7540d725e65ac7f1b212ac8ce349719624d7bcff99f8e2e488e8cf03f" | ||
@@ -235,5 +241,5 @@ [[package]] | ||
| name = "errno" | ||
| version = "0.3.8" | ||
| version = "0.3.9" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "a258e46cdc063eb8519c00b9fc845fc47bcfca4130e2f08e88665ceda8474245" | ||
| checksum = "534c5cf6194dfab3db3242765c03bbe257cf92f22b38f6bc0c58d59108a820ba" | ||
| dependencies = [ | ||
@@ -388,6 +394,7 @@ "libc", | ||
| name = "h2" | ||
| version = "0.4.4" | ||
| version = "0.4.5" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "816ec7294445779408f36fe57bc5b7fc1cf59664059096c65f905c1c61f58069" | ||
| checksum = "fa82e28a107a8cc405f0839610bdc9b15f1e25ec7d696aa5cf173edbcb1486ab" | ||
| dependencies = [ | ||
| "atomic-waker", | ||
| "bytes", | ||
@@ -397,3 +404,2 @@ "fnv", | ||
| "futures-sink", | ||
| "futures-util", | ||
| "http", | ||
@@ -588,5 +594,5 @@ "indexmap", | ||
| name = "libc" | ||
| version = "0.2.154" | ||
| version = "0.2.155" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "ae743338b92ff9146ce83992f766a31066a91a8c84a45e0e9f21e7cf6de6d346" | ||
| checksum = "97b3888a4aecf77e811145cadf6eef5901f4782c53886191b2f693f24761847c" | ||
@@ -605,5 +611,5 @@ [[package]] | ||
| name = "linux-raw-sys" | ||
| version = "0.4.13" | ||
| version = "0.4.14" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "01cda141df6706de531b6c46c3a33ecca755538219bd484262fa09410c13539c" | ||
| checksum = "78b3ae25bc7c8c38cec158d1f2757ee79e9b3740fbc7ccf0e59e4b08d793fa89" | ||
@@ -649,5 +655,5 @@ [[package]] | ||
| name = "miniz_oxide" | ||
| version = "0.7.2" | ||
| version = "0.7.3" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "9d811f3e15f28568be3407c8e7fdb6514c1cda3cb30683f15b6a1a1dc4ea14a7" | ||
| checksum = "87dfd01fe195c66b572b37921ad8803d010623c0aca821bea2302239d155cdae" | ||
| dependencies = [ | ||
@@ -836,5 +842,5 @@ "adler", | ||
| name = "proc-macro2" | ||
| version = "1.0.81" | ||
| version = "1.0.83" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "3d1597b0c024618f09a9c3b8655b7e430397a36d23fdafec26d6965e9eec3eba" | ||
| checksum = "0b33eb56c327dec362a9e55b3ad14f9d2f0904fb5a5b03b513ab5465399e9f43" | ||
| dependencies = [ | ||
@@ -1009,5 +1015,5 @@ "unicode-ident", | ||
| name = "rustc-demangle" | ||
| version = "0.1.23" | ||
| version = "0.1.24" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "d626bb9dae77e28219937af045c257c28bfd3f69333c512553507f5f9798cb76" | ||
| checksum = "719b953e2095829ee67db738b3bfa9fa368c94900df327b3f07fe6e794d2fe1f" | ||
@@ -1039,11 +1045,11 @@ [[package]] | ||
| name = "rustls-pki-types" | ||
| version = "1.5.0" | ||
| version = "1.7.0" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "beb461507cee2c2ff151784c52762cf4d9ff6a61f3e80968600ed24fa837fa54" | ||
| checksum = "976295e77ce332211c0d24d92c0e83e50f5c5f046d11082cea19f3df13a3562d" | ||
| [[package]] | ||
| name = "ryu" | ||
| version = "1.0.17" | ||
| version = "1.0.18" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "e86697c916019a8588c99b5fac3cead74ec0b4b819707a682fd4d23fa0ce1ba1" | ||
| checksum = "f3cb5ba0dc43242ce17de99c180e96db90b235b8a9fdc9543c96d2209116bd9f" | ||
@@ -1090,5 +1096,5 @@ [[package]] | ||
| name = "serde" | ||
| version = "1.0.200" | ||
| version = "1.0.202" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "ddc6f9cc94d67c0e21aaf7eda3a010fd3af78ebf6e096aa6e2e13c79749cce4f" | ||
| checksum = "226b61a0d411b2ba5ff6d7f73a476ac4f8bb900373459cd00fab8512828ba395" | ||
| dependencies = [ | ||
@@ -1100,5 +1106,5 @@ "serde_derive", | ||
| name = "serde_derive" | ||
| version = "1.0.200" | ||
| version = "1.0.202" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "856f046b9400cee3c8c94ed572ecdb752444c24528c035cd35882aad6f492bcb" | ||
| checksum = "6048858004bcff69094cd972ed40a32500f153bd3be9f716b2eed2e8217c4838" | ||
| dependencies = [ | ||
@@ -1112,5 +1118,5 @@ "proc-macro2", | ||
| name = "serde_json" | ||
| version = "1.0.116" | ||
| version = "1.0.117" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "3e17db7126d17feb94eb3fad46bf1a96b034e8aacbc2e775fe81505f8b0b2813" | ||
| checksum = "455182ea6142b14f93f4bc5320a2b31c1f266b66a4a5c858b013302a5d8cbfc3" | ||
| dependencies = [ | ||
@@ -1149,3 +1155,3 @@ "itoa", | ||
| name = "servicing" | ||
| version = "0.0.11" | ||
| version = "0.0.12" | ||
| dependencies = [ | ||
@@ -1204,5 +1210,5 @@ "base64", | ||
| name = "syn" | ||
| version = "2.0.60" | ||
| version = "2.0.65" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "909518bc7b1c9b779f1bbf07f2929d35af9f0f37e47c6e9ef7f9dddc1e1821f3" | ||
| checksum = "d2863d96a84c6439701d7a38f9de935ec562c8832cc55d1dde0f513b52fad106" | ||
| dependencies = [ | ||
@@ -1261,5 +1267,5 @@ "proc-macro2", | ||
| name = "thiserror" | ||
| version = "1.0.59" | ||
| version = "1.0.61" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "f0126ad08bff79f29fc3ae6a55cc72352056dfff61e3ff8bb7129476d44b23aa" | ||
| checksum = "c546c80d6be4bc6a00c0f01730c08df82eaa7a7a61f11d656526506112cc1709" | ||
| dependencies = [ | ||
@@ -1271,5 +1277,5 @@ "thiserror-impl", | ||
| name = "thiserror-impl" | ||
| version = "1.0.59" | ||
| version = "1.0.61" | ||
| source = "registry+https://github.com/rust-lang/crates.io-index" | ||
| checksum = "d1cd413b5d558b4c5bf3680e324a6fa5014e7b7c067a51e69dbdf47eb7148b66" | ||
| checksum = "46c3384250002a6d5af4d114f2845d37b57521033f30d5c3f46c4d70e1197533" | ||
| dependencies = [ | ||
@@ -1276,0 +1282,0 @@ "proc-macro2", |
+1
-1
| [package] | ||
| name = "servicing" | ||
| version = "0.0.11" | ||
| version = "0.0.12" | ||
| edition = "2021" | ||
@@ -5,0 +5,0 @@ |
+1
-1
| Metadata-Version: 2.3 | ||
| Name: servicing | ||
| Version: 0.0.11 | ||
| Version: 0.0.12 | ||
| Classifier: Programming Language :: Rust | ||
@@ -5,0 +5,0 @@ Classifier: Programming Language :: Python :: Implementation :: CPython |
+2
-1
@@ -41,3 +41,4 @@ from typing import List, Optional | ||
| def __init__(self) -> None: ... | ||
| def __init__(self, | ||
| skip_sky_validation: Optional[bool] = False) -> None: ... | ||
@@ -44,0 +45,0 @@ def add_service(self, name: str, |
@@ -14,3 +14,4 @@ #![allow(dead_code)] // Remove this later | ||
| use log::{error, info, warn}; | ||
| use pyo3::{pyclass, pymethods, Bound, PyAny}; | ||
| use pyo3::prelude::*; | ||
| use pyo3::{pyclass, pymethods, types::PyDict, Bound, PyAny}; | ||
| use regex::Regex; | ||
@@ -61,5 +62,14 @@ use reqwest::Client; | ||
| #[pyo3(signature = (*_args, **_kwargs))] | ||
| pub fn new(_args: &Bound<'_, PyAny>, _kwargs: Option<&Bound<'_, PyAny>>) -> Result<Self, ServicingError> { | ||
| pub fn new( | ||
| _args: &Bound<'_, PyAny>, | ||
| _kwargs: Option<&Bound<'_, PyAny>>, | ||
| ) -> Result<Self, ServicingError> { | ||
| // Check if sky_check is True in _kwargs | ||
| let skip_sky_validation = _kwargs | ||
| .and_then(|kwargs| kwargs.downcast::<PyDict>().ok()) | ||
| .and_then(|dict| dict.get_item("skip_sky_validation").unwrap_or(None)) | ||
| .map(|sky_check| sky_check.is_truthy().unwrap_or(false)).unwrap_or(false); | ||
| // Check if the user has installed the required python package | ||
| if !helper::check_python_package_installed(CLUSTER_ORCHESTRATOR) { | ||
| if !skip_sky_validation && !helper::check_python_package_installed(CLUSTER_ORCHESTRATOR) { | ||
| return Err(ServicingError::PipPackageError(CLUSTER_ORCHESTRATOR)); | ||
@@ -66,0 +76,0 @@ } |
| use pyo3::{pyclass, pymethods}; | ||
| use serde::{ser::SerializeStruct, Deserialize, Serialize}; | ||
| #[pyclass] | ||
| #[pyclass(subclass)] | ||
| #[derive(Clone, Serialize, Deserialize, Debug)] | ||
@@ -6,0 +6,0 @@ pub struct UserProvidedConfig { |
Alert delta unavailable
Currently unable to show alert delta for PyPI packages.
88121
0.78%101
1%