mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-10-28 00:02:42 +00:00
feat(cache): remove persistent raw values from queue (#4866)
* feat(cache): remove persistent raw values from queue * test: add tests and fix discovered regressions * fix csharp executor after rebase * invalidate script cache after locking * fix lite flow version race * fix flow dependencies lock race * update version flag to `v.1.440`
This commit is contained in:
@@ -508,7 +508,7 @@ fn copy_dir_recursively(src: &Path, dst: &Path) -> windmill_common::error::Resul
|
||||
|
||||
#[tracing::instrument(level = "trace", skip_all)]
|
||||
pub async fn handle_python_job(
|
||||
requirements_o: Option<String>,
|
||||
requirements_o: Option<&String>,
|
||||
job_dir: &str,
|
||||
worker_dir: &str,
|
||||
worker_name: &str,
|
||||
@@ -1049,7 +1049,7 @@ async fn replace_pip_secret(
|
||||
|
||||
async fn handle_python_deps(
|
||||
job_dir: &str,
|
||||
requirements_o: Option<String>,
|
||||
requirements_o: Option<&String>,
|
||||
inner_content: &str,
|
||||
w_id: &str,
|
||||
script_path: &str,
|
||||
@@ -1072,12 +1072,13 @@ async fn handle_python_deps(
|
||||
.clone();
|
||||
|
||||
let annotations = windmill_common::worker::PythonAnnotations::parse(inner_content);
|
||||
let mut requirements;
|
||||
let requirements = match requirements_o {
|
||||
Some(r) => r,
|
||||
None => {
|
||||
let mut already_visited = vec![];
|
||||
|
||||
let requirements = windmill_parser_py_imports::parse_python_imports(
|
||||
requirements = windmill_parser_py_imports::parse_python_imports(
|
||||
inner_content,
|
||||
w_id,
|
||||
script_path,
|
||||
@@ -1086,10 +1087,8 @@ async fn handle_python_deps(
|
||||
)
|
||||
.await?
|
||||
.join("\n");
|
||||
if requirements.is_empty() {
|
||||
"".to_string()
|
||||
} else {
|
||||
uv_pip_compile(
|
||||
if !requirements.is_empty() {
|
||||
requirements = uv_pip_compile(
|
||||
job_id,
|
||||
&requirements,
|
||||
mem_peak,
|
||||
@@ -1105,8 +1104,9 @@ async fn handle_python_deps(
|
||||
.await
|
||||
.map_err(|e| {
|
||||
Error::ExecutionErr(format!("pip compile failed: {}", e.to_string()))
|
||||
})?
|
||||
})?;
|
||||
}
|
||||
&requirements
|
||||
}
|
||||
};
|
||||
|
||||
@@ -1899,7 +1899,7 @@ use windmill_common::variables;
|
||||
|
||||
#[cfg(feature = "enterprise")]
|
||||
pub async fn start_worker(
|
||||
requirements_o: Option<String>,
|
||||
requirements_o: Option<&String>,
|
||||
db: &sqlx::Pool<sqlx::Postgres>,
|
||||
inner_content: &str,
|
||||
base_internal_url: &str,
|
||||
|
||||
Reference in New Issue
Block a user