Skip to content

Commit 6667f36

Browse files
adwk67claude
andcommitted
feat: remove product-config crate dependency
Vendors the Flask Python-config writer locally (flask_config_writer) and drops the airflow-operator's direct product-config dependency. The rendered webserver_config.py is unchanged (the vendored writer is byte-for-byte faithful to the crate). product-config remains a transitive dependency via stackable-operator. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
1 parent 1f4e351 commit 6667f36

8 files changed

Lines changed: 329 additions & 10 deletions

File tree

Cargo.lock

Lines changed: 0 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.nix

Lines changed: 0 additions & 4 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,6 @@ edition = "2021"
1010
repository = "https://github.com/stackabletech/airflow-operator"
1111

1212
[workspace.dependencies]
13-
product-config = { git = "https://github.com/stackabletech/product-config.git", tag = "0.8.0" }
1413
stackable-operator = { git = "https://github.com/stackabletech/operator-rs.git", features = [
1514
"crds",
1615
"webhook",

rust/operator-binary/Cargo.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,6 @@ repository.workspace = true
99
publish = false
1010

1111
[dependencies]
12-
product-config.workspace = true
1312
stackable-operator.workspace = true
1413

1514
anyhow.workspace = true

rust/operator-binary/src/airflow_controller.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ use std::{
66
};
77

88
use const_format::concatcp;
9-
use product_config::flask_app_config_writer::{self, FlaskAppConfigWriterError};
109
use snafu::{OptionExt, ResultExt, Snafu};
1110
use stackable_operator::{
1211
builder::{
@@ -93,6 +92,7 @@ use crate::{
9392
v1alpha2,
9493
},
9594
env_vars::{self, build_airflow_template_envs},
95+
flask_config_writer::{self, FlaskAppConfigWriterError},
9696
operations::{
9797
graceful_shutdown::{
9898
add_airflow_graceful_shutdown_config, add_executor_graceful_shutdown_config,
@@ -754,7 +754,7 @@ fn build_rolegroup_config_map(
754754

755755
let temp_file_footer: Option<String> = config.remove(CONFIG_OVERRIDE_FILE_FOOTER_KEY);
756756

757-
flask_app_config_writer::write::<AirflowConfigOptions, _, _>(
757+
flask_config_writer::write::<AirflowConfigOptions, _, _>(
758758
&mut config_file,
759759
config.iter(),
760760
PYTHON_IMPORTS,

rust/operator-binary/src/crd/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,5 @@
11
use std::collections::{BTreeMap, BTreeSet, HashMap};
22

3-
use product_config::flask_app_config_writer::{FlaskAppConfigOptions, PythonType};
43
use serde::{Deserialize, Serialize};
54
use snafu::{OptionExt, ResultExt, Snafu};
65
use stackable_operator::{
@@ -56,6 +55,7 @@ use crate::{
5655
CeleryBrokerConnection, CeleryResultBackendConnection, MetadataDatabaseConnection,
5756
},
5857
},
58+
flask_config_writer::{FlaskAppConfigOptions, PythonType},
5959
util::role_service_name,
6060
};
6161

0 commit comments

Comments
 (0)