Skip to content

Commit 2d32691

Browse files
committed
fix
1 parent 3a9eb01 commit 2d32691

File tree

2 files changed

+8
-5
lines changed

2 files changed

+8
-5
lines changed

src/iceberg/json_internal.cc

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -548,10 +548,11 @@ Result<std::unique_ptr<PartitionSpec>> PartitionSpecFromJson(
548548
if (default_spec_id == spec_id) {
549549
ICEBERG_ASSIGN_OR_RAISE(
550550
spec, PartitionSpec::Make(*schema, spec_id, std::move(partition_fields),
551-
true /*allow_missing_fields*/));
551+
/*allow_missing_fields=*/false));
552552
} else {
553-
ICEBERG_ASSIGN_OR_RAISE(spec,
554-
PartitionSpec::Make(spec_id, std::move(partition_fields)));
553+
ICEBERG_ASSIGN_OR_RAISE(
554+
spec, PartitionSpec::Make(*schema, spec_id, std::move(partition_fields),
555+
/*allow_missing_fields=*/true));
555556
}
556557
return spec;
557558
}
@@ -928,8 +929,9 @@ Status ParsePartitionSpecs(const nlohmann::json& json, int8_t format_version,
928929

929930
// Create partition spec with schema validation
930931
ICEBERG_ASSIGN_OR_RAISE(
931-
auto spec, PartitionSpec::Make(*current_schema, PartitionSpec::kInitialSpecId,
932-
std::move(fields), true /*allow_missing_fields*/));
932+
auto spec,
933+
PartitionSpec::Make(*current_schema, PartitionSpec::kInitialSpecId,
934+
std::move(fields), /*allow_missing_fields=*/false));
933935
default_spec_id = spec->spec_id();
934936
partition_specs.push_back(std::move(spec));
935937
}

src/iceberg/test/manifest_reader_writer_test.cc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,7 @@
3434
#include "iceberg/test/temp_file_test_base.h"
3535
#include "iceberg/test/test_common.h"
3636
#include "iceberg/transform.h"
37+
#include "iceberg/type.h"
3738

3839
namespace iceberg {
3940

0 commit comments

Comments
 (0)