@@ -30,8 +30,8 @@ use typed_builder::TypedBuilder;
3030
3131use self :: _const_schema:: { manifest_schema_v1, manifest_schema_v2} ;
3232use super :: {
33- Datum , FieldSummary , FormatVersion , ManifestContentType , ManifestFile , PartitionSpec , Schema ,
34- SchemaId , SchemaRef , Struct , INITIAL_SEQUENCE_NUMBER , UNASSIGNED_SEQUENCE_NUMBER ,
33+ BoundPartitionSpec , Datum , FieldSummary , FormatVersion , ManifestContentType , ManifestFile ,
34+ Schema , SchemaId , SchemaRef , Struct , INITIAL_SEQUENCE_NUMBER , UNASSIGNED_SEQUENCE_NUMBER ,
3535} ;
3636use crate :: error:: Result ;
3737use crate :: io:: OutputFile ;
@@ -706,7 +706,7 @@ pub struct ManifestMetadata {
706706 /// ID of the schema used to write the manifest as a string
707707 schema_id : SchemaId ,
708708 /// The partition spec used to write the manifest
709- partition_spec : PartitionSpec ,
709+ partition_spec : BoundPartitionSpec ,
710710 /// Table format version number of the manifest as a string
711711 format_version : FormatVersion ,
712712 /// Type of content files tracked by the manifest: “data” or “deletes”
@@ -773,7 +773,7 @@ impl ManifestMetadata {
773773 } )
774774 . transpose ( ) ?
775775 . unwrap_or ( 0 ) ;
776- PartitionSpec :: builder ( schema. clone ( ) )
776+ BoundPartitionSpec :: builder ( schema. clone ( ) )
777777 . with_spec_id ( spec_id)
778778 . add_unbound_fields ( fields. into_iter ( ) . map ( |f| f. into_unbound ( ) ) ) ?
779779 . build ( ) ?
@@ -1594,7 +1594,7 @@ mod tests {
15941594 metadata : ManifestMetadata {
15951595 schema_id : 0 ,
15961596 schema : schema. clone ( ) ,
1597- partition_spec : PartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
1597+ partition_spec : BoundPartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
15981598 content : ManifestContentType :: Data ,
15991599 format_version : FormatVersion :: V2 ,
16001600 } ,
@@ -1707,7 +1707,7 @@ mod tests {
17071707 metadata : ManifestMetadata {
17081708 schema_id : 0 ,
17091709 schema : schema. clone ( ) ,
1710- partition_spec : PartitionSpec :: builder ( schema)
1710+ partition_spec : BoundPartitionSpec :: builder ( schema)
17111711 . with_spec_id ( 0 ) . add_partition_field ( "v_int" , "v_int" , Transform :: Identity ) . unwrap ( )
17121712 . add_partition_field ( "v_long" , "v_long" , Transform :: Identity ) . unwrap ( ) . build ( ) . unwrap ( ) ,
17131713 content : ManifestContentType :: Data ,
@@ -1818,7 +1818,7 @@ mod tests {
18181818 metadata : ManifestMetadata {
18191819 schema_id : 1 ,
18201820 schema : schema. clone ( ) ,
1821- partition_spec : PartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
1821+ partition_spec : BoundPartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
18221822 content : ManifestContentType :: Data ,
18231823 format_version : FormatVersion :: V1 ,
18241824 } ,
@@ -1882,7 +1882,7 @@ mod tests {
18821882 metadata : ManifestMetadata {
18831883 schema_id : 0 ,
18841884 schema : schema. clone ( ) ,
1885- partition_spec : PartitionSpec :: builder ( schema) . add_partition_field ( "category" , "category" , Transform :: Identity ) . unwrap ( ) . build ( ) . unwrap ( ) ,
1885+ partition_spec : BoundPartitionSpec :: builder ( schema) . add_partition_field ( "category" , "category" , Transform :: Identity ) . unwrap ( ) . build ( ) . unwrap ( ) ,
18861886 content : ManifestContentType :: Data ,
18871887 format_version : FormatVersion :: V1 ,
18881888 } ,
@@ -1961,7 +1961,7 @@ mod tests {
19611961 metadata : ManifestMetadata {
19621962 schema_id : 0 ,
19631963 schema : schema. clone ( ) ,
1964- partition_spec : PartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
1964+ partition_spec : BoundPartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
19651965 content : ManifestContentType :: Data ,
19661966 format_version : FormatVersion :: V2 ,
19671967 } ,
@@ -2033,7 +2033,7 @@ mod tests {
20332033 metadata : ManifestMetadata {
20342034 schema_id : 0 ,
20352035 schema : schema. clone ( ) ,
2036- partition_spec : PartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
2036+ partition_spec : BoundPartitionSpec :: builder ( schema) . with_spec_id ( 0 ) . build ( ) . unwrap ( ) ,
20372037 content : ManifestContentType :: Data ,
20382038 format_version : FormatVersion :: V2 ,
20392039 } ,
0 commit comments