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
Assert.Equal() Failure: Values differ
Expected: Done
Actual: DestinationTooSmall
at System.IO.Compression.EncoderDecoderTestBase.RoundTrip_AllWindowLogs()
````
## Suspected Root Cause
PR #127394 replaced `MemoryMarshal.Read<T>` / `MemoryMarshal.Write<T>` calls with `BitConverter.ToInt32` / `BitConverter.GetBytes` equivalents throughout the codebase. While the PR didn't directly modify compression code, it did modify `BitConverterPolyfills.cs`, which may be used by the compression encoders/decoders on platforms where the native BitConverter methods aren't available.
The failure suggests that buffer size calculations or endianness handling may have changed subtly, causing the encoder to report `DestinationTooSmall` when it should complete successfully.
## Failure Details
**Build:** https://dev.azure.com/dnceng-public/public/_build/results?buildId=1396313
**Affected Jobs:** All Android Mono jobs (arm, arm64, x64, x86), likely iOS/tvOS/MacCatalyst as well
**Sample Helix Work Item:**
- Job ID: `93091357-214b-436d-a5c4-a31ee456a876`
- Work Item: `System.IO.Compression.Tests`
- Console log: https://helix.dot.net/api/2019-06-17/jobs/93091357-214b-436d-a5c4-a31ee456a876/workitems/System.IO.Compression.Tests/console
**Log excerpt:**
````
04-24 21:04:03.088 DOTNET : [FAIL] System.IO.Compression.DeflateEncoderDecoderTests.RoundTrip_AllWindowLogs
04-24 21:04:03.088 DOTNET : Assert.Equal() Failure: Values differ
04-24 21:04:03.088 DOTNET : Expected: Done
04-24 21:04:03.088 DOTNET : Actual: DestinationTooSmall
Investigation Needed
Compare behavior of MemoryMarshal.Read<int> vs BitConverter.ToInt32 on Android/mobile platforms
Check if BitConverterPolyfills.cs is being used on these platforms
Verify endianness handling in the polyfill vs the original MemoryMarshal calls
Review all compression-related code paths that might indirectly use BitConverter
Note
This content was generated by GitHub Copilot.
Description
Three compression encoder/decoder tests started failing on Android (and likely all mobile platforms) after PR #127394 was merged:
System.IO.Compression.DeflateEncoderDecoderTests.RoundTrip_AllWindowLogsSystem.IO.Compression.ZLibEncoderDecoderTests.RoundTrip_AllWindowLogsSystem.IO.Compression.GZipEncoderDecoderTests.RoundTrip_AllWindowLogsAll three fail with the same assertion:
Investigation Needed
MemoryMarshal.Read<int>vsBitConverter.ToInt32on Android/mobile platformsBitConverterPolyfills.csis being used on these platformsRelated
Note
🔒 Integrity filter blocked 1 item
The following item were blocked because they don't meet the GitHub integrity level.
search_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".To allow these resources, lower
min-integrityin your GitHub frontmatter: