diff --git a/backend/Cargo.lock b/backend/Cargo.lock index a4449f8fe2..b842b0fd38 100644 --- a/backend/Cargo.lock +++ b/backend/Cargo.lock @@ -15656,29 +15656,18 @@ name = "windmill" version = "1.628.3" dependencies = [ "anyhow", - "aws-sdk-config", - "aws-sigv4", "axum 0.7.9", "base64 0.22.1", - "bitflags 2.9.4", "chrono", "constant_time_eq 0.3.1", "dotenv", "futures", "gethostname", "git-version", - "globset", - "k8s-openapi", - "kube", "lazy_static", - "libloading 0.8.9", - "memchr", "object_store", "once_cell", - "opentelemetry-proto 0.29.0", - "pep440_rs", "prometheus", - "quote", "rand 0.9.0", "reqwest 0.13.1", "rustls 0.23.35", @@ -15691,7 +15680,6 @@ dependencies = [ "sql-builder", "sqlx", "strum 0.27.2", - "systemstat", "tempfile", "tikv-jemalloc-ctl", "tikv-jemalloc-sys", diff --git a/backend/Cargo.toml b/backend/Cargo.toml index 5ae09ccef0..72a4a05d67 100644 --- a/backend/Cargo.toml +++ b/backend/Cargo.toml @@ -206,20 +206,8 @@ windmill-runtime-nativets = { workspace = true, optional = true } object_store = { workspace = true, optional = true } sha1 = { workspace = true, optional = true } constant_time_eq = { workspace = true, optional = true } -quote.workspace = true -memchr.workspace = true rustls.workspace = true -pep440_rs.workspace = true strum.workspace = true -aws-sigv4.workspace = true -aws-sdk-config.workspace = true -kube.workspace = true -k8s-openapi.workspace = true -libloading.workspace = true -bitflags.workspace = true -globset.workspace = true -opentelemetry-proto.workspace = true -systemstat.workspace = true [target.'cfg(windows)'.dependencies] windows-service = "0.7" diff --git a/backend/windmill-api-scripts/Cargo.toml b/backend/windmill-api-scripts/Cargo.toml index c167eff11a..407348ee72 100644 --- a/backend/windmill-api-scripts/Cargo.toml +++ b/backend/windmill-api-scripts/Cargo.toml @@ -12,6 +12,7 @@ path = "src/lib.rs" default = [] enterprise = ["windmill-common/enterprise"] private = ["windmill-common/private"] +python = ["dep:windmill-parser-py"] [dependencies] windmill-common = { workspace = true, default-features = false } @@ -37,4 +38,4 @@ tracing.workspace = true chrono.workspace = true lazy_static.workspace = true tokio.workspace = true -windmill-parser-py.workspace = true +windmill-parser-py = { workspace = true, optional = true } diff --git a/backend/windmill-api-scripts/src/scripts.rs b/backend/windmill-api-scripts/src/scripts.rs index 06aa1df1a1..3462788bcf 100644 --- a/backend/windmill-api-scripts/src/scripts.rs +++ b/backend/windmill-api-scripts/src/scripts.rs @@ -832,6 +832,7 @@ async fn create_script_internal<'c>( } } } + #[cfg(feature = "python")] ScriptLang::Python3 => { let args = windmill_parser_py::parse_python_signature(&ns.content, None, true); match args { diff --git a/backend/windmill-api/Cargo.toml b/backend/windmill-api/Cargo.toml index 72f3580dbf..8e3c7d2818 100644 --- a/backend/windmill-api/Cargo.toml +++ b/backend/windmill-api/Cargo.toml @@ -18,7 +18,7 @@ agent_worker_server = ["dep:windmill-worker"] enterprise_saml = ["dep:samael", "dep:libxml"] benchmark = [] embedding = ["windmill-api-embeddings/embedding"] -parquet = ["dep:datafusion", "dep:object_store", "windmill-common/parquet", "windmill-worker?/parquet", "windmill-api-users/parquet"] +parquet = ["dep:datafusion", "dep:object_store", "windmill-common/parquet", "windmill-worker?/parquet", "windmill-api-users/parquet", "dep:aws-sigv4", "dep:aws-sdk-config"] prometheus = ["windmill-common/prometheus", "windmill-queue/prometheus", "dep:prometheus", "windmill-worker?/prometheus"] openidconnect = ["dep:openidconnect", "windmill-common/openidconnect", "windmill-store/openidconnect"] tantivy = ["dep:windmill-indexer"] @@ -39,8 +39,8 @@ sqs_trigger = ["dep:windmill-trigger-sqs", "windmill-store/sqs_trigger"] gcp_trigger = ["dep:windmill-trigger-gcp", "windmill-store/gcp_trigger"] cloud = ["windmill-common/cloud", "windmill-api-auth/cloud", "windmill-store/cloud", "windmill-api-workspaces/cloud"] mcp = ["dep:windmill-mcp", "windmill-mcp/server", "windmill-mcp/auth", "windmill-api-auth/mcp", "windmill-store/mcp"] -bedrock = ["dep:aws-sdk-bedrock", "dep:aws-sdk-bedrockruntime", "windmill-common/bedrock", "dep:aws-config"] -python = ["windmill-dep-map/python"] +bedrock = ["dep:aws-sdk-bedrock", "dep:aws-sdk-bedrockruntime", "windmill-common/bedrock", "dep:aws-config", "dep:aws-credential-types", "dep:aws-smithy-types"] +python = ["windmill-dep-map/python", "dep:windmill-parser-py", "dep:windmill-parser-py-imports", "windmill-api-scripts/python", "windmill-trigger/python", "windmill-common/python"] no_auth = ["windmill-api-auth/no_auth", "windmill-store/no_auth", "windmill-api-users/no_auth"] [dependencies] @@ -60,8 +60,8 @@ windmill-audit.workspace = true windmill-parser.workspace = true windmill-parser-sql.workspace = true windmill-parser-ts.workspace = true -windmill-parser-py.workspace = true -windmill-parser-py-imports.workspace = true +windmill-parser-py = { workspace = true, optional = true } +windmill-parser-py-imports = { workspace = true, optional = true } windmill-git-sync.workspace = true windmill-indexer = { workspace = true, optional = true } windmill-autoscaling.workspace = true @@ -150,13 +150,13 @@ async-stream.workspace = true ulid.workspace = true rustls = { workspace = true } -aws-sigv4.workspace = true -aws-sdk-config.workspace = true +aws-sigv4 = { workspace = true, optional = true } +aws-sdk-config = { workspace = true, optional = true } aws-config = { workspace = true, optional = true } -aws-credential-types.workspace = true +aws-credential-types = { workspace = true, optional = true } aws-sdk-bedrock = { workspace = true, optional = true } aws-sdk-bedrockruntime = { workspace = true, optional = true } -aws-smithy-types.workspace = true +aws-smithy-types = { workspace = true, optional = true } async-trait.workspace = true windmill-jseval.workspace = true tar.workspace = true diff --git a/backend/windmill-common/Cargo.toml b/backend/windmill-common/Cargo.toml index 029505eb6c..4faa1fefd3 100644 --- a/backend/windmill-common/Cargo.toml +++ b/backend/windmill-common/Cargo.toml @@ -22,6 +22,7 @@ scoped_cache = [] cloud = [] openidconnect = ["dep:openidconnect"] bedrock = ["dep:aws-sdk-bedrockruntime", "dep:aws-credential-types", "dep:aws-smithy-types", "dep:aws-config"] +python = ["dep:windmill-parser-py"] [lib] name = "windmill_common" @@ -90,7 +91,7 @@ crc.workspace = true windmill-macros.workspace = true windmill-parser-sql.workspace = true windmill-parser-ts.workspace = true -windmill-parser-py.workspace = true +windmill-parser-py = { workspace = true, optional = true } windmill-parser.workspace = true jsonwebtoken.workspace = true backon.workspace = true diff --git a/backend/windmill-common/src/jobs.rs b/backend/windmill-common/src/jobs.rs index b1497c3d3e..d9e500ef86 100644 --- a/backend/windmill-common/src/jobs.rs +++ b/backend/windmill-common/src/jobs.rs @@ -564,6 +564,7 @@ pub fn get_has_preprocessor_from_content_and_lang( let args = windmill_parser_ts::parse_deno_signature(&content, true, true, None)?; args.has_preprocessor.unwrap_or(false) } + #[cfg(feature = "python")] ScriptLang::Python3 => { let args = windmill_parser_py::parse_python_signature(&content, None, true)?; args.has_preprocessor.unwrap_or(false) diff --git a/backend/windmill-trigger/Cargo.toml b/backend/windmill-trigger/Cargo.toml index 3cff7db14e..8132f8b62a 100644 --- a/backend/windmill-trigger/Cargo.toml +++ b/backend/windmill-trigger/Cargo.toml @@ -12,6 +12,7 @@ path = "src/lib.rs" default = [] enterprise = ["windmill-common/enterprise", "windmill-api-jobs/enterprise"] cloud = ["windmill-common/cloud"] +python = ["dep:windmill-parser-py"] [dependencies] windmill-api-auth.workspace = true @@ -40,4 +41,4 @@ rand.workspace = true itertools.workspace = true windmill-parser.workspace = true windmill-parser-ts.workspace = true -windmill-parser-py.workspace = true +windmill-parser-py = { workspace = true, optional = true } diff --git a/backend/windmill-trigger/src/trigger_helpers.rs b/backend/windmill-trigger/src/trigger_helpers.rs index f1b7d18fa5..b50cdb69a3 100644 --- a/backend/windmill-trigger/src/trigger_helpers.rs +++ b/backend/windmill-trigger/src/trigger_helpers.rs @@ -210,6 +210,7 @@ fn get_preprocessor_args_from_content_and_language( )?; Some(args.args) } + #[cfg(feature = "python")] ScriptLang::Python3 => { let args = windmill_parser_py::parse_python_signature( &content, diff --git a/backend/windmill-worker/Cargo.toml b/backend/windmill-worker/Cargo.toml index 4735838c03..619d092c7e 100644 --- a/backend/windmill-worker/Cargo.toml +++ b/backend/windmill-worker/Cargo.toml @@ -37,7 +37,7 @@ nu = ["dep:windmill-parser-nu"] java = ["dep:windmill-parser-java"] ruby = ["dep:windmill-parser-ruby"] duckdb = ["dep:libloading"] -bedrock = ["dep:aws-sdk-bedrockruntime", "windmill-common/bedrock"] +bedrock = ["dep:aws-sdk-bedrockruntime", "windmill-common/bedrock", "dep:aws-config", "dep:aws-credential-types", "dep:aws-smithy-types"] [dependencies] windmill-queue.workspace = true @@ -65,9 +65,9 @@ windmill-parser-graphql.workspace = true windmill-parser-php = { workspace = true, optional = true } windmill-git-sync.workspace = true aws-sdk-bedrockruntime = { workspace = true, optional = true } -aws-config.workspace = true -aws-credential-types.workspace = true -aws-smithy-types.workspace = true +aws-config = { workspace = true, optional = true } +aws-credential-types = { workspace = true, optional = true } +aws-smithy-types = { workspace = true, optional = true } flume.workspace = true sqlx.workspace = true uuid.workspace = true