4B #9
Omena0
announced in
Announcements
4B
#9
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
4B
Client-mod API consolidation release — high-level Python interface, cleaner extension exports, and client/runtime hardening and readability improvements.
Changes
ClientModSession-First APIclient_modfrombridge.extensions.client_mod.ClientModSession(cm = client_mod.session(player)) and methods likecm.command(...),cm.register_script(...),cm.raycast(...),cm.stream_audio_file(...), andcm.stream_audio_generator(...).client_mod.on_client_data,client_mod.on_permission_change,client_mod.register_request_data(...),client_mod.unregister_request_data(...).bridge.extensionsto favor object-based API usage (ClientMod,ClientModSession,client_mod) over flat helper-only usage.BridgeInstanceand Event Routing CorrectnessBridgeInstance.scriptOnlySubscriptionssoBridgeInstance.hasSubscription(...),BridgeInstance.getSubscriptionNames(), and dispatch matching include script-local handlers.BridgeInstance.resolveInvokeResult(...)to correctly resolve nestedCompletableFuturereturns with timeout/error propagation into Python responses.BridgeInstanceto returnserver.broadcastMessage(...)behavior instead of log-only side effects.BridgeInstance(sendBlockChange) with explicitMaterial.matchMaterial(...)null checks beforeBukkit.createBlockData(...).Serializer/Facade Guard Rails
BridgeSerializerinventory validation indeserialize(...)(sizemust be9..54and a multiple of9).BridgeSerializerBlockdeserialization (no hiddenblock.setType(...)side effects).BridgeSerializer.coerceArg(...)to explicitly parse"true"/"false"string inputs.RegionFacade.pasteOperations(...)and stronger invalid block-data failure behavior inRegionFacade.parseBlockData(...).ClientModFrameCodec.decodeFrame(...).Python Runtime Concurrency and Lifecycle Safety
BridgeConnectionlocking around_pending_syncand batching (_pending_sync_lock,_batch_lock) to avoid races between reader/caller threads.BridgeConnection.flush()atomically snapshot/clear_batch_messagesand_batch_futuresbefore sendingcall_batch.server.atomic()now yields an int-like counter (with server.atomic() as num_failed:/async with ...) andserver.flush()returns the aborted-call count for the flushed batch.BridgeConnectionso pending sync waits are finalized safely and loop stop is scheduled via_loop.call_soon(...).wrappers.py(_handle_refcounts_lock) and deterministic LRU-like UUID cache helpers (_cache_get_player_uuid,_cache_set_player_uuid).Extension Correctness and Recovery Paths
ability.py,combat.py,quest.py,leaderboard.py,scheduler.py, andstate_machine.py.bank.py,levels.py,player_data.py,guild.py).trade.pyby checkingbank.withdraw(...)return values and refunding on partial failure.dungeon.py,schematic.py,mesh_display.py,image_display.py,loot_table.py,tab_list.py).client_mod.py(ffmpegstdout checks, producer error propagation, guaranteed stop infinally).Docs, CI, and Packaging Follow-Through
docs/build.pyto avoid basename collisions in output names, source maps, and search URLs..github/workflows/deploy-pages.ymltool dependencies for reproducible docs deployments.src/main/resources/python/bridge/MANIFEST(loot_table.py,placeholder.py,scheduler.py,schematic.py,state_machine.py,tab_list.py).bridge/__init__.pyiandbridge/extensions/__init__.pyi.--productionflag, which converts all links to absolute links (/PyJavaBridge/world.htmlinstead of/world.html) for better SEO.This discussion was created from the release 4B.
Beta Was this translation helpful? Give feedback.
All reactions