fix(python): default ImageResponse buffers to empty bytes/list#9810
Open
Bartok9 wants to merge 1 commit into
microsoft:mainmicrosoft/AirSim:mainfrom
Bartok9:aerial/2026-07-24-image-response-defaultsBartok9/AirSim:aerial/2026-07-24-image-response-defaultsCopy head branch name to clipboard
Open
fix(python): default ImageResponse buffers to empty bytes/list#9810Bartok9 wants to merge 1 commit intomicrosoft:mainmicrosoft/AirSim:mainfrom Bartok9:aerial/2026-07-24-image-response-defaultsBartok9/AirSim:aerial/2026-07-24-image-response-defaultsCopy head branch name to clipboard
Bartok9 wants to merge 1 commit into
microsoft:mainmicrosoft/AirSim:mainfrom
Bartok9:aerial/2026-07-24-image-response-defaultsBartok9/AirSim:aerial/2026-07-24-image-response-defaultsCopy head branch name to clipboard
Conversation
image_data_uint8 was np.uint8(0) and image_data_float was 0.0, which breaks len()/frombuffer paths used throughout PythonClient samples. Align with vector-shaped RPC payloads.
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.
Summary
Default
ImageResponse.image_data_uint8/image_data_floatwere scalar placeholders (np.uint8(0)and0.0). Sample code and helpers calllen(...)andnp.frombufferon those fields; empty bytes and an empty list match the RPC vector payloads.Motivation
Prevents TypeError on cold construction and documents the intended container shapes for clients that inspect responses before a capture fills them.
Verification
PythonClient/tests/test_image_response_types.py(package import needs msgpackrpc when deps present).RpcLibAdaptorsBase::ImageResponsevectors.AI-assisted scoping; human-reviewed micro-diff.
Claim: bartok
Operator: bartok
Campaign: aerial-drone