Skip to content

Add tests for nested field drop/re-add ID behavior in schema evolution#16145

Draft
longvu-db wants to merge 2 commits into
apache:mainfrom
longvu-db:long.vu/nested-field-id-tests
Draft

Add tests for nested field drop/re-add ID behavior in schema evolution#16145
longvu-db wants to merge 2 commits into
apache:mainfrom
longvu-db:long.vu/nested-field-id-tests

Conversation

@longvu-db
Copy link
Copy Markdown

Summary

  • Add 6 tests to TestSchemaUpdate verifying that parent and sibling field IDs are preserved when nested fields are dropped, re-added, or expanded in structs, lists, and maps
  • Tests confirm IDs are never recycled, parent struct/list/map IDs are unaffected by child mutations, and maxColumnId increments monotonically

Test scenarios

  • Drop+re-add nested struct field with different name
  • Drop+re-add nested field with same name (ID never recycled)
  • Drop+re-add field in struct nested in list
  • Drop+re-add field in struct nested in map value
  • Drop-only nested field (parent and sibling IDs preserved)
  • Add-only nested field (existing IDs preserved, fresh ID assigned)

Generated-by: Claude Opus 4.6

Add 6 tests to TestSchemaUpdate verifying that parent and sibling field
IDs are preserved when nested fields are dropped, re-added, or expanded
in structs, lists, and maps:

- Drop+re-add nested struct field with different name
- Drop+re-add nested field with same name (ID never recycled)
- Drop+re-add field in struct nested in list
- Drop+re-add field in struct nested in map value
- Drop-only nested field (parent and sibling IDs preserved)
- Add-only nested field (existing IDs preserved, fresh ID assigned)

Co-authored-by: Isaac
@github-actions github-actions Bot added the core label Apr 28, 2026
@longvu-db longvu-db marked this pull request as draft April 28, 2026 21:02
@github-actions
Copy link
Copy Markdown

This pull request has been marked as stale due to 30 days of inactivity. It will be closed in 1 week if no further activity occurs. If you think that’s incorrect or this pull request requires a review, please simply write any comment. If closed, you can revive the PR at any time and @mention a reviewer or discuss it on the dev@iceberg.apache.org list. Thank you for your contributions.

@github-actions github-actions Bot added the stale label May 29, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant