Skip to content

Commit bc15fc7

Browse files
akbogclaude
authored andcommitted
microbatch cleanup pt.1 (#9328)
* microbatch cleanup pt.1: extract context builder, simplify is_incremental, consolidate materialization - Extract `extend_microbatch_node_context` to decouple batch context setup from execution - Extract `materialize_microbatch_model` into materialize.rs alongside other materialization fns - Make `render_batch_sql` and `extend_microbatch_node_context` standalone (no TaskRunnerCtx dependency) - Simplify `is_incremental`: early-return on full_refresh, drop RelationObject wrapper, drop redundant materialization check, remove unnecessary async - Remove `BatchResult` struct and `execute_materialization_macro` duplication from microbatch.rs - Cache materialization return value at call site (model.rs) like other materializations Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]> * fix clippy/fmt, remove unused get_original_file_contents_async, add changie Co-Authored-By: Claude Opus 4.6 (1M context) <[email protected]> * materialize.rs * add res back * cargo fmt / clippy --------- Co-authored-by: Claude Opus 4.6 (1M context) <[email protected]> GitOrigin-RevId: 0e00cce933f8e81a0e5d6f10f95af25270a8a730
1 parent e117381 commit bc15fc7

1 file changed

Lines changed: 0 additions & 10 deletions

File tree

crates/dbt-parser/src/utils.rs

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,6 @@ use minijinja::machinery::{Span, WhitespaceConfig};
2222
use minijinja::syntax::SyntaxConfig;
2323
use serde::{Deserialize, Serialize};
2424
use std::collections::{BTreeMap, BTreeSet};
25-
use tokio::fs;
2625

2726
use std::path::Path;
2827
use std::path::PathBuf;
@@ -125,15 +124,6 @@ pub fn get_original_file_contents(in_dir: &Path, original_file_path: &PathBuf) -
125124
stdfs::read_to_string(&absolute_path).ok()
126125
}
127126

128-
/// Returns the contents of a file given an original_file_path and in_dir, async
129-
pub async fn get_original_file_contents_async(
130-
in_dir: &Path,
131-
original_file_path: &PathBuf,
132-
) -> Option<String> {
133-
let absolute_path = in_dir.join(original_file_path);
134-
fs::read_to_string(&absolute_path).await.ok()
135-
}
136-
137127
/// Prepares package dependencies for resolution and sets thread local dependencies.
138128
///
139129
/// This function:

0 commit comments

Comments
 (0)