Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Compression RoundTrip_AllWindowLogs tests failing on Android after PR #127394 #127421

Copy link
Copy link

Description

@github-actions
Issue body actions

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:

  1. System.IO.Compression.DeflateEncoderDecoderTests.RoundTrip_AllWindowLogs
  2. System.IO.Compression.ZLibEncoderDecoderTests.RoundTrip_AllWindowLogs
  3. System.IO.Compression.GZipEncoderDecoderTests.RoundTrip_AllWindowLogs

All three fail with the same assertion:

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

  1. Compare behavior of MemoryMarshal.Read<int> vs BitConverter.ToInt32 on Android/mobile platforms
  2. Check if BitConverterPolyfills.cs is being used on these platforms
  3. Verify endianness handling in the polyfill vs the original MemoryMarshal calls
  4. Review all compression-related code paths that might indirectly use BitConverter

Related

Note

🔒 Integrity filter blocked 1 item

The following item were blocked because they don't meet the GitHub integrity level.

  • #126805 search_pull_requests: has lower integrity than agent requires. The agent cannot read data with integrity below "approved".

To allow these resources, lower min-integrity in your GitHub frontmatter:

tools:
  github:
    min-integrity: approved  # merged | approved | unapproved | none

Generated by Mobile Platform Failure Scanner · ● 4.1M ·

Reactions are currently unavailable

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions

Morty Proxy This is a proxified and sanitized view of the page, visit original site.