apache / iceberg-rust

Apache Iceberg
https://rust.iceberg.apache.org/
Apache License 2.0
469 stars 95 forks source link

Remove #[allow(dead_code)] from the codebase #421

Closed vivek378521 closed 3 days ago

Xuanwo commented 4 days ago

cc @liurenjie1024 for a review.

Do we need to make pub(crate) fn avro_schema_to_schema(avro_schema: &AvroSchema) -> Result<Schema> a public function?

liurenjie1024 commented 3 days ago

Hi, @vivek378521 Thanks for contributing, I checked the error and have following suggestions:

  1. avro_schema_to_schema currently only used for tests, but IIRC it's still useful, I would suggest to move it to tests
  2. column_names in TableScan is useful for debugging, I would suggest to have a public method to expose it
  3. For others they seem actually useless, we can remove them.
vivek378521 commented 3 days ago

Hey @liurenjie1024

I have made the changes that you suggested. The tests are passing and things are working as expected. Please review.

Thanks.

vivek378521 commented 3 days ago

@liurenjie1024 I have changed the function name as suggested, thanks! :)

liurenjie1024 commented 3 days ago

@liurenjie1024 I have changed the function name as suggested, thanks! :)

Thanks for contribution!