You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Fix editBook external test crash on MC 1.20.2+ (TypeError on null nbt)
In MC 1.20.5+ the server returns book items using structured components
(writable_book_content / written_book_content) instead of NBT, so
book.nbt is null and accessing book.nbt.value.pages throws.
Additionally, for some versions the server may not echo back page data
in the set_slot response for writable_book at all.
This commit adds helper functions that extract pages, title, and author
from either the legacy NBT format or the new componentMap, and makes
content assertions conditional on the data actually being present.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
0 commit comments