Repository navigation
chore!: integrate upstream login hardening and registry context fixes - #27
Merged
Merged
Conversation
…3382) Debug hive and POI values write their counts as VarInts, and debug game events write their position as doubles. DebugChunkValuePacket takes chunk x and z and packs x into the low bits of the chunk position. DeleteChatPacket holds a packed signature, so it can delete by cache index as well as by full signature. Minecart lerp steps pack their rotations into LP_FLOAT, and item templates write the component patch instead of every default component. World border lerp and initialize packets carry the transition time in ticks. WorldBorder.createLerpSizePacket and createInitializePacket take ticks. (Breaking) On the serverbound side, the change difficulty packet has no locked flag, the structure block seed is a VarLong, and beacon effects are mob effects.
Deleted by just making our own NBT reader/writer, which is likely better. Already deprecated for removal.
Port of FFM work
* refactor: NetworkBuffer#resizableBuffer should take long Instead of int, breaking change though I think it's fine to have a ABI incompatible one compared to a source incompatible one where it tries to pick the bridge. * fix: update usage in jmh
Lets callers serialize components without an initialized server process.
Raw values decoded with different registry contexts compare equal.
Each enchantment table uses the registry it was created with. This likely needs to be refactored to be deferred lookup only when the property needs to be sent, so it's not a requirement to pass this, it's not like it matters so much for scratch though.
…tom#3392) Copies also keep the dimension name.
…tPacket (Minestom#3395) The damage type ID is resolved when the packet is written.
…3396) Pooled buffers hold no registries until a write sets them.
Bumps the non-breaking group with 3 updates: [gradle-wrapper](https://github.com/gradle/gradle), [ch.qos.logback:logback-core](https://github.com/qos-ch/logback) and [ch.qos.logback:logback-classic](https://github.com/qos-ch/logback). Updates `gradle-wrapper` from 9.7.1 to 9.8.0 - [Release notes](https://github.com/gradle/gradle/releases) - [Commits](gradle/gradle@v9.7.1...v9.8.0) Updates `ch.qos.logback:logback-core` from 1.6.3 to 1.6.5 - [Release notes](https://github.com/qos-ch/logback/releases) - [Commits](qos-ch/logback@v_1.6.3...v_1.6.5) Updates `ch.qos.logback:logback-classic` from 1.6.3 to 1.6.5 - [Release notes](https://github.com/qos-ch/logback/releases) - [Commits](qos-ch/logback@v_1.6.3...v_1.6.5) Updates `ch.qos.logback:logback-classic` from 1.6.3 to 1.6.5 - [Release notes](https://github.com/qos-ch/logback/releases) - [Commits](qos-ch/logback@v_1.6.3...v_1.6.5) --- updated-dependencies: - dependency-name: gradle-wrapper dependency-version: 9.8.0 dependency-type: direct:production update-type: version-update:semver-minor dependency-group: non-breaking - dependency-name: ch.qos.logback:logback-core dependency-version: 1.6.5 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: non-breaking - dependency-name: ch.qos.logback:logback-classic dependency-version: 1.6.5 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: non-breaking - dependency-name: ch.qos.logback:logback-classic dependency-version: 1.6.5 dependency-type: direct:production update-type: version-update:semver-patch dependency-group: non-breaking ... Signed-off-by: dependabot[bot] <support@github.com> Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com>
RegistryKey.of and TagKey.of replace unsafeOf. A key will become just a typed key, it was never really a proof of registration as you could simply register and unregister a entry in a dynamic registry regardless. Drops unsafeOf as they are internal (Though I know they are used so I will include migration notes and mark this as breaking)
Integrates Minestom/Minestom@5485bbd50f. Registries remain owned by the ServerProcess, so upstream's per-instance Registries constructors and global-registry fallbacks are not adopted. BREAKING CHANGE: RegistryKey/TagKey unsafeOf is renamed to of, NetworkBuffer.IOView and other upstream APIs deprecated for removal are gone, Tool's Block overloads are removed, and DamageEventPacket carries a damage type key.
Binary CompatibilityThis Pull Request has introduced binary incompatible changes compared to the What is Binary Compatibility? What should you do?
View offending signatures |
Adopts upstream's Registries overloads on Instance, InstanceContainer, InstanceManager and EnchantmentTableInventory, with the owning ServerProcess prepended. The process-only constructors stay undeprecated and default to the process's registries. Copies, shared instances and chunk tag handlers follow the instance's registries.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We were 22 commits behind upstream, including a security fix: a client could finish configuration before the server did and break spawning. This brings all of it in.
Integrates Minestom/Minestom@5485bbd50f.
How it fits the fork
Upstream's main theme was letting callers pick a
Registriesper instance/inventory to replaceMinecraftServer.getRegistries(). Those overloads are adopted with the owningServerProcessprepended, so the API stays in step with upstream:InstanceandInstanceContainergain(ServerProcess, Registries, ...)constructors;InstanceManager.createInstanceContainergainsRegistriesoverloads.EnchantmentTableInventorycan take theRegistry<Enchantment>that assigns displayed IDs.The one difference from upstream: the constructors without a
Registriesargument are not deprecated. Upstream deprecates them because they fall back to the global registries; here they default to the process's registries, which is the right default.The bug fixes riding along are kept:
MinestomDataComponentValue).Breaking
RegistryKey/TagKeyunsafeOf→of.NetworkBuffer.IOViewand upstream's other deprecated-for-removal API removed; fork's deprecatedTool(Registry, Block)overloads removed to match.DamageEventPacketcarries aRegistryKey<DamageType>.Tests
Upstream tests built on the global pool/registries are dropped; their assertions are ported to process-based
InstanceContainerTestandEnchantmentTableInventoryTest, which also cover explicit registries (including a dimension and an enchantment registered only in the explicit context).:test,:testing:test, and:javadocpassed locally on the integration commit; the registry-context follow-up was checked with those two test classes.🤖 Generated with Claude Code