You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@datafusion.apache.org by gi...@apache.org on 2026/04/14 23:48:41 UTC
(datafusion) 01/01: chore: Fix `typo` problems (#21495)
This is an automated email from the ASF dual-hosted git repository.
github-bot pushed a commit to branch gh-readonly-queue/main/pr-21495-f9239a197f2c49b69a87efb5ef25fd67b13b7ca1
in repository https://gitbox.apache.org/repos/asf/datafusion.git
commit ccbcdedc57e67e8027c3acf2b82ce181f4e9f734
Author: Eren Avsarogullari <er...@apache.org>
AuthorDate: Tue Apr 14 16:48:18 2026 -0700
chore: Fix `typo` problems (#21495)
## Which issue does this PR close?
- Closes #21494.
## Rationale for this change
There are typo problems on following source-files and some of them were
being highlighted by IntelliJ (CLion). It is useful to fix them:
```
datafusion/
benchmarks/bench.sh
benchmarks/lineprotocol.py
core/src/execution/context/mod.rs
expr/src/udf.rs
functions-nested/src/range.rs
optimizer/src/optimizer.rs
optimizer/src/optimizer.rs
physical-plan/src/joins/nested_loop_join.rs
sqllogictest/src/engines/datafusion_engine/normalize.rs
sqllogictest/test_files/repartition.slt
```
## What changes are included in this PR?
This PR aims to fix found typo problems.
## Are these changes tested?
Not required.
## Are there any user-facing changes?
No
---
benchmarks/bench.sh | 2 +-
benchmarks/lineprotocol.py | 4 ++--
datafusion/core/src/execution/context/mod.rs | 6 +++---
datafusion/expr/src/udf.rs | 2 +-
datafusion/functions-nested/src/range.rs | 2 +-
datafusion/optimizer/src/optimizer.rs | 2 +-
datafusion/physical-optimizer/src/optimizer.rs | 2 +-
datafusion/physical-plan/src/joins/nested_loop_join.rs | 4 ++--
datafusion/sqllogictest/src/engines/datafusion_engine/normalize.rs | 2 +-
datafusion/sqllogictest/test_files/repartition.slt | 2 +-
10 files changed, 14 insertions(+), 14 deletions(-)
diff --git a/benchmarks/bench.sh b/benchmarks/bench.sh
index badf9ce435..abd1801213 100755
--- a/benchmarks/bench.sh
+++ b/benchmarks/bench.sh
@@ -900,7 +900,7 @@ data_imdb() {
if [ "${DOWNLOADED_SIZE}" != "${expected_size}" ]; then
echo "Error: Download size mismatch"
echo "Expected: ${expected_size}"
- echo "Got: ${DOWNLADED_SIZE}"
+ echo "Got: ${DOWNLOADED_SIZE}"
echo "Please re-initiate the download"
return 1
fi
diff --git a/benchmarks/lineprotocol.py b/benchmarks/lineprotocol.py
index 75e09b662e..40f643499f 100644
--- a/benchmarks/lineprotocol.py
+++ b/benchmarks/lineprotocol.py
@@ -164,12 +164,12 @@ def lineformat(
) -> None:
baseline = BenchmarkRun.load_from_file(baseline)
context = baseline.context
- benchamrk_str = f"benchmark,name={context.name},version={context.benchmark_version},datafusion_version={context.datafusion_version},num_cpus={context.num_cpus}"
+ benchmark_str = f"benchmark,name={context.name},version={context.benchmark_version},datafusion_version={context.datafusion_version},num_cpus={context.num_cpus}"
for query in baseline.queries:
query_str = f"query=\"{query.query}\""
timestamp = f"{query.start_time*10**9}"
for iter_num, result in enumerate(query.iterations):
- print(f"{benchamrk_str} {query_str},iteration={iter_num},row_count={result.row_count},elapsed_ms={result.elapsed*1000:.0f} {timestamp}\n")
+ print(f"{benchmark_str} {query_str},iteration={iter_num},row_count={result.row_count},elapsed_ms={result.elapsed*1000:.0f} {timestamp}\n")
def main() -> None:
parser = ArgumentParser()
diff --git a/datafusion/core/src/execution/context/mod.rs b/datafusion/core/src/execution/context/mod.rs
index 75ddfd5247..b879973e7d 100644
--- a/datafusion/core/src/execution/context/mod.rs
+++ b/datafusion/core/src/execution/context/mod.rs
@@ -254,7 +254,7 @@ where
/// let state = SessionStateBuilder::new()
/// .with_config(config)
/// .with_runtime_env(runtime_env)
-/// // include support for built in functions and configurations
+/// // include support for built-in functions and configurations
/// .with_default_features()
/// .build();
///
@@ -1087,8 +1087,8 @@ impl SessionContext {
}
}
- fn schema_doesnt_exist_err(&self, schemaref: &SchemaReference) -> Result<DataFrame> {
- exec_err!("Schema '{schemaref}' doesn't exist.")
+ fn schema_doesnt_exist_err(&self, schema_ref: &SchemaReference) -> Result<DataFrame> {
+ exec_err!("Schema '{schema_ref}' doesn't exist.")
}
async fn set_variable(&self, stmt: SetVariable) -> Result<()> {
diff --git a/datafusion/expr/src/udf.rs b/datafusion/expr/src/udf.rs
index ee88580e0f..6a3aa31a86 100644
--- a/datafusion/expr/src/udf.rs
+++ b/datafusion/expr/src/udf.rs
@@ -587,7 +587,7 @@ pub trait ScalarUDFImpl: Debug + DynEq + DynHash + Send + Sync + Any {
///
/// If you provide an implementation for [`Self::return_field_from_args`],
/// DataFusion will not call `return_type` (this function). While it is
- /// valid to to put [`unimplemented!()`] or [`unreachable!()`], it is
+ /// valid to put [`unimplemented!()`] or [`unreachable!()`], it is
/// recommended to return [`DataFusionError::Internal`] instead, which
/// reduces the severity of symptoms if bugs occur (an error rather than a
/// panic).
diff --git a/datafusion/functions-nested/src/range.rs b/datafusion/functions-nested/src/range.rs
index 346fb8d0f3..c51b008191 100644
--- a/datafusion/functions-nested/src/range.rs
+++ b/datafusion/functions-nested/src/range.rs
@@ -289,7 +289,7 @@ impl Range {
///
/// # Arguments
///
- /// * `args` - An array of 1 to 3 ArrayRefs representing start, stop, and step(step value can not be zero.) values.
+ /// * `args` - An array of 1 to 3 ArrayRefs representing start, stop, and step (step value can not be zero) values.
///
/// # Examples
///
diff --git a/datafusion/optimizer/src/optimizer.rs b/datafusion/optimizer/src/optimizer.rs
index bdea6a8307..d0fbb31414 100644
--- a/datafusion/optimizer/src/optimizer.rs
+++ b/datafusion/optimizer/src/optimizer.rs
@@ -496,7 +496,7 @@ impl Optimizer {
/// These are invariants which should hold true before and after [`LogicalPlan`] optimization.
///
/// This differs from [`LogicalPlan::check_invariants`], which addresses if a singular
-/// LogicalPlan is valid. Instead this address if the optimization was valid based upon permitted changes.
+/// LogicalPlan is valid. Instead, this address if the optimization was valid based upon permitted changes.
fn assert_valid_optimization(
plan: &LogicalPlan,
prev_schema: &Arc<DFSchema>,
diff --git a/datafusion/physical-optimizer/src/optimizer.rs b/datafusion/physical-optimizer/src/optimizer.rs
index d9ddaa8943..be24344dee 100644
--- a/datafusion/physical-optimizer/src/optimizer.rs
+++ b/datafusion/physical-optimizer/src/optimizer.rs
@@ -221,7 +221,7 @@ impl PhysicalOptimizer {
Arc::new(PushdownSort::new()),
Arc::new(EnsureCooperative::new()),
// This FilterPushdown handles dynamic filters that may have references to the source ExecutionPlan.
- // Therefore it should be run at the end of the optimization process since any changes to the plan may break the dynamic filter's references.
+ // Therefore, it should be run at the end of the optimization process since any changes to the plan may break the dynamic filter's references.
// See `FilterPushdownPhase` for more details.
Arc::new(FilterPushdown::new_post_optimization()),
// The SanityCheckPlan rule checks whether the order and
diff --git a/datafusion/physical-plan/src/joins/nested_loop_join.rs b/datafusion/physical-plan/src/joins/nested_loop_join.rs
index 9ca2052e93..951e3e3690 100644
--- a/datafusion/physical-plan/src/joins/nested_loop_join.rs
+++ b/datafusion/physical-plan/src/joins/nested_loop_join.rs
@@ -2265,7 +2265,7 @@ impl NestedLoopJoinStream {
bitmap.set_bit(l_index, true);
}
- // 2. Maybe updateh the right bitmap
+ // 2. Maybe update the right bitmap
if self.should_track_unmatched_right {
debug_assert!(self.current_right_batch_matched.is_some());
// after bit-wise or, it will be put back
@@ -2596,7 +2596,7 @@ fn build_unmatched_batch(
// 2. Fill left side with nulls
let flipped_bitmap = not(&batch_bitmap)?;
- // create a recordbatch, with left_schema, of only one row of all nulls
+ // create a record batch, with left_schema, of only one row of all nulls
let left_null_columns: Vec<Arc<dyn Array>> = another_side_schema
.fields()
.iter()
diff --git a/datafusion/sqllogictest/src/engines/datafusion_engine/normalize.rs b/datafusion/sqllogictest/src/engines/datafusion_engine/normalize.rs
index bad9a1dd3f..2c549422d6 100644
--- a/datafusion/sqllogictest/src/engines/datafusion_engine/normalize.rs
+++ b/datafusion/sqllogictest/src/engines/datafusion_engine/normalize.rs
@@ -253,7 +253,7 @@ pub fn cell_to_string(col: &ArrayRef, row: usize, is_spark_path: bool) -> Result
}
}
-/// Converts columns to a result as expected by sqllogicteset.
+/// Converts columns to a result as expected by sqllogictest.
pub fn convert_schema_to_types(columns: &Fields) -> Vec<DFColumnType> {
columns
.iter()
diff --git a/datafusion/sqllogictest/test_files/repartition.slt b/datafusion/sqllogictest/test_files/repartition.slt
index f05458f866..cf913caefc 100644
--- a/datafusion/sqllogictest/test_files/repartition.slt
+++ b/datafusion/sqllogictest/test_files/repartition.slt
@@ -123,7 +123,7 @@ physical_plan
03)----RepartitionExec: partitioning=RoundRobinBatch(3), input_partitions=1
04)------StreamingTableExec: partition_sizes=1, projection=[c1, c2, c3], infinite_source=true
-# Start repratition on empty column test.
+# Start repartition on empty column test.
# See https://github.com/apache/datafusion/issues/12057
statement ok
---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@datafusion.apache.org
For additional commands, e-mail: commits-help@datafusion.apache.org