Random Test
This commit is contained in:
Generated
+1488
File diff suppressed because it is too large
Load Diff
+6
-1
@@ -7,4 +7,9 @@ edition = "2024"
|
||||
crate-type = ["cdylib"]
|
||||
|
||||
[dependencies]
|
||||
pyo3 = "0.27.0"
|
||||
pyo3 = { version = "0.27.0", features = ["extension-module"] }
|
||||
reqwest = "0.12.24"
|
||||
serde = "1.0.228"
|
||||
|
||||
[package.metadata.maturin]
|
||||
generate-abi-stubs = true
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
from typing import Dict, List, Optional
|
||||
|
||||
def pull_policy_exec_histories(self, type: List[str], checkpoint: str, policy: List[str]) -> str:
|
||||
"""Retrieve execution history logs."""
|
||||
@@ -0,0 +1,5 @@
|
||||
#!/bin/bash
|
||||
cargo clean
|
||||
maturin build
|
||||
python3 -m pip uninstall airlock_libs --break-system-packages
|
||||
python3 -m pip install target/wheels/airlock_libs-0.1.0-cp313-cp313-manylinux_2_34_x86_64.whl --break-system-packages
|
||||
@@ -0,0 +1,3 @@
|
||||
import airlock_libs
|
||||
|
||||
airlock_libs.pull_policy_exec_histories()
|
||||
+4
-1
@@ -1,8 +1,11 @@
|
||||
use pyo3::prelude::*;
|
||||
mod chunkinator;
|
||||
mod services;
|
||||
#[pymodule]
|
||||
fn python_ext(py: Python<'_>, m: &Bound<'_, PyModule>) -> PyResult<()> {
|
||||
fn airlock_libs(py: Python<'_>, m: &Bound<'_, PyModule>) -> PyResult<()> {
|
||||
m.add_function(wrap_pyfunction!(double, py)?)?;
|
||||
m.add_function(wrap_pyfunction!(services::pull_policy_exec_histories, py)?)?;
|
||||
m.add_function(wrap_pyfunction!(services::api, py)?)?;
|
||||
Ok(())
|
||||
}
|
||||
#[pyfunction]
|
||||
|
||||
@@ -0,0 +1,11 @@
|
||||
use pyo3::prelude::*;
|
||||
|
||||
#[pyfunction]
|
||||
pub fn pull_policy_exec_histories() {
|
||||
println!("Hello World from Rust!");
|
||||
}
|
||||
|
||||
#[pyfunction]
|
||||
pub fn api(x: String) {
|
||||
println!("{}", x);
|
||||
}
|
||||
Reference in New Issue
Block a user