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
{{ message }}
Repository navigation
[PR] fix: preserve non-image Google inline media during image shedding - #6184
The Google collector treats every inlineData part as an image. Gemini also carries audio, video and documents in that field, so a byte or image-count limit can replace those parts with an image-omitted note. Undeclared media is likewise assumed to be PNG without evidence.
Changes
Collect Google inlineData only when its declared MIME type is image/*. Preserve non-image and unknown media in both byte and count shedding; image archiving and protected-tail behavior continue as before.
Rebased onto master e3220adc0f5412af83163666ca70a6afa05e3247 (package version 0.1.213). The intervening [PR] thirdparty-scan: flag dsh-live-compact as a known conflict (#5984) #6166 changes only third-party plugin detection, its tests, announcements and configuration docs; none of this patch's source or test files changed. The complete patch is byte-identical to the locally validated patch on 33104b1f9545caeb0344193009917ceef9969682 and applies cleanly.
Negative control on 33104b1f9545caeb0344193009917ceef9969682: 8 new regression cases still fail before the production fix.
Independent source tree based on 33104b1f9545caeb0344193009917ceef9969682 (5f3c2d54180ecacc9a5f664a970e236caa0d25d5): 30/30 focused tests passed, with no failures, skips or cancellations.
Full project TypeScript checking and the standard npm run build passed on the temporary integration tree e186774d3428c85e2a4974c6e609b2a7381d6153 containing the seven independently submitted fixes on 33104b1f9545caeb0344193009917ceef9969682. The repository compiler options and include set are unchanged.
git diff --check passed. Local runtime: Node.js 24.22.1 on Linux. Full cross-platform remote CI remains pending.
This change filters the wire collector and is independent of the image encode-cache MIME key in #6109. No configuration or kernel changes.
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
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.
Fixes #6176
Problem
The Google collector treats every inlineData part as an image. Gemini also carries audio, video and documents in that field, so a byte or image-count limit can replace those parts with an image-omitted note. Undeclared media is likewise assumed to be PNG without evidence.
Changes
Collect Google inlineData only when its declared MIME type is image/*. Preserve non-image and unknown media in both byte and count shedding; image archiving and protected-tail behavior continue as before.
Google's Part/Blob schema documents these non-image media types: https://ai.google.dev/api/generate-content#Blob
Validation
e3220adc0f5412af83163666ca70a6afa05e3247(package version0.1.213). The intervening [PR] thirdparty-scan: flag dsh-live-compact as a known conflict (#5984) #6166 changes only third-party plugin detection, its tests, announcements and configuration docs; none of this patch's source or test files changed. The complete patch is byte-identical to the locally validated patch on33104b1f9545caeb0344193009917ceef9969682and applies cleanly.33104b1f9545caeb0344193009917ceef9969682: 8 new regression cases still fail before the production fix.33104b1f9545caeb0344193009917ceef9969682(5f3c2d54180ecacc9a5f664a970e236caa0d25d5): 30/30 focused tests passed, with no failures, skips or cancellations.npm run buildpassed on the temporary integration treee186774d3428c85e2a4974c6e609b2a7381d6153containing the seven independently submitted fixes on33104b1f9545caeb0344193009917ceef9969682. The repository compiler options and include set are unchanged.git diff --checkpassed. Local runtime: Node.js 24.22.1 on Linux. Full cross-platform remote CI remains pending.This change filters the wire collector and is independent of the image encode-cache MIME key in #6109. No configuration or kernel changes.