Skip to content

Commit 3ac0651

Browse files
authored
chore(deps): fix bump typos to v1.30.0 (#1029)
## Which issue does this PR close? <!-- We generally require a GitHub issue to be filed for all bug fixes and enhancements and this helps us generate change logs for our releases. You can link an issue to this PR using the GitHub syntax. For example `Closes #123` indicates that this PR will close issue #1018 . --> - Fixes #1018 . ## What changes are included in this PR? <!-- Provide a summary of the modifications in this PR. List the main changes such as new features, bug fixes, refactoring, or any other updates. --> ## Are these changes tested? <!-- Specify what test covers (unit test, integration test, etc.). If tests are not included in your PR, please explain why (for example, are they covered by existing tests)? -->
1 parent 2101345 commit 3ac0651

File tree

3 files changed

+12
-10
lines changed

3 files changed

+12
-10
lines changed

Diff for: .github/workflows/ci_typos.yml

+1-1
Original file line numberDiff line numberDiff line change
@@ -42,4 +42,4 @@ jobs:
4242
steps:
4343
- uses: actions/checkout@v4
4444
- name: Check typos
45-
uses: crate-ci/typos@v1.29.7
45+
uses: crate-ci/typos@v1.30.0

Diff for: crates/iceberg/src/arrow/schema.rs

+2-2
Original file line numberDiff line numberDiff line change
@@ -677,11 +677,11 @@ pub(crate) fn get_arrow_datum(datum: &Datum) -> Result<Box<dyn ArrowDatum + Send
677677
.with_timezone("UTC"),
678678
))),
679679

680-
(typ, _) => Err(Error::new(
680+
(primitive_type, _) => Err(Error::new(
681681
ErrorKind::FeatureUnsupported,
682682
format!(
683683
"Converting datum from type {:?} to arrow not supported yet.",
684-
typ
684+
primitive_type
685685
),
686686
)),
687687
}

Diff for: crates/iceberg/src/avro/schema.rs

+9-7
Original file line numberDiff line numberDiff line change
@@ -442,13 +442,14 @@ impl AvroSchemaVisitor for AvroSchemaToSchema {
442442
field_types: Vec<Option<Type>>,
443443
) -> Result<Option<Type>> {
444444
let mut fields = Vec::with_capacity(field_types.len());
445-
for (avro_field, typ) in record.fields.iter().zip_eq(field_types) {
445+
for (avro_field, field_type) in record.fields.iter().zip_eq(field_types) {
446446
let field_id =
447447
Self::get_element_id_from_attributes(&avro_field.custom_attributes, FILED_ID_PROP)?;
448448

449449
let optional = is_avro_optional(&avro_field.schema);
450450

451-
let mut field = NestedField::new(field_id, &avro_field.name, typ.unwrap(), !optional);
451+
let mut field =
452+
NestedField::new(field_id, &avro_field.name, field_type.unwrap(), !optional);
452453

453454
if let Some(doc) = &avro_field.doc {
454455
field = field.with_doc(doc);
@@ -514,7 +515,7 @@ impl AvroSchemaVisitor for AvroSchemaToSchema {
514515
}
515516

516517
fn primitive(&mut self, schema: &AvroSchema) -> Result<Option<Type>> {
517-
let typ = match schema {
518+
let schema_type = match schema {
518519
AvroSchema::Decimal(decimal) => {
519520
Type::decimal(decimal.precision as u32, decimal.scale as u32)?
520521
}
@@ -561,7 +562,7 @@ impl AvroSchemaVisitor for AvroSchemaToSchema {
561562
}
562563
};
563564

564-
Ok(Some(typ))
565+
Ok(Some(schema_type))
565566
}
566567

567568
fn map_array(
@@ -610,15 +611,16 @@ impl AvroSchemaVisitor for AvroSchemaToSchema {
610611
pub(crate) fn avro_schema_to_schema(avro_schema: &AvroSchema) -> Result<Schema> {
611612
if let AvroSchema::Record(_) = avro_schema {
612613
let mut converter = AvroSchemaToSchema;
613-
let typ = visit(avro_schema, &mut converter)?.expect("Iceberg schema should not be none.");
614-
if let Type::Struct(s) = typ {
614+
let schema_type =
615+
visit(avro_schema, &mut converter)?.expect("Iceberg schema should not be none.");
616+
if let Type::Struct(s) = schema_type {
615617
Schema::builder()
616618
.with_fields(s.fields().iter().cloned())
617619
.build()
618620
} else {
619621
Err(Error::new(
620622
ErrorKind::Unexpected,
621-
format!("Expected to convert avro record schema to struct type, but {typ}"),
623+
format!("Expected to convert avro record schema to struct type, but {schema_type}"),
622624
))
623625
}
624626
} else {

0 commit comments

Comments
 (0)