Skip to content

System.IO.Compression.Tests.ZipFile_Unix.UnixCreateSetsPermissionsInExternalAttributes fail on OSX #68293

Closed

Description

@runfoapp
Starting:    System.IO.Compression.ZipFile.Tests (parallel test collections = on, max threads = 6)
  System.IO.Compression.Tests.ZipFile_Unix.UnixCreateSetsPermissionsInExternalAttributes [FAIL]
    Assert.Equal() Failure
    Expected: 3968
    Actual:   2944
    Stack Trace:
      /_/src/libraries/System.IO.Compression.ZipFile/tests/ZipFile.Unix.cs(43,0): at System.IO.Compression.Tests.ZipFile_Unix.<UnixCreateSetsPermissionsInExternalAttributes>g__EnsureExternalAttributes|0_0(String permissions, ZipArchiveEntry entry)
      /_/src/libraries/System.IO.Compression.ZipFile/tests/ZipFile.Unix.cs(38,0): at System.IO.Compression.Tests.ZipFile_Unix.UnixCreateSetsPermissionsInExternalAttributes()
         at System.RuntimeMethodHandle.InvokeMethod(Object target, Void** arguments, Signature sig, Boolean isConstructor)
      /_/src/coreclr/System.Private.CoreLib/src/System/Reflection/RuntimeMethodInfo.CoreCLR.cs(379,0): at System.Reflection.RuntimeMethodInfo.InvokeNonEmitUnsafe(Object obj, IntPtr* arguments, Span`1 argsForTemporaryMonoSupport, BindingFlags invokeAttr)

Runfo Tracking Issue: System.IO.Compression.Tests.ZipFile_Unix.UnixCreateSetsPermissionsInExternalAttributes fail on OSX

Build Definition Kind Run Name Console Core Dump Test Results Run Client
1780676 runtime PR 69583 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1780676 runtime PR 69583 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1780676 runtime PR 69583 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1752830 runtime PR 68876 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1752830 runtime PR 68876 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1752830 runtime PR 68876 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1752422 runtime Rolling net6.0-OSX-Release-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1752422 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1752422 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1752118 runtime Rolling net6.0-OSX-Release-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1752118 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1752118 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1752112 runtime PR 68352 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1752112 runtime PR 68352 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1752112 runtime PR 68352 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1751402 runtime PR 67901 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1751402 runtime PR 67901 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1751402 runtime PR 67901 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1751109 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1751109 runtime Rolling net6.0-OSX-Release-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1751109 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1750872 runtime PR 68425 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1750872 runtime PR 68425 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1750872 runtime PR 68425 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1750836 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1750836 runtime Rolling net6.0-OSX-Release-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1750836 runtime Rolling net6.0-OSX-Release-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1750701 runtime PR 68825 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1750701 runtime PR 68825 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1750701 runtime PR 68825 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1749891 runtime PR 68825 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1749891 runtime PR 68825 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1749891 runtime PR 68825 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1744574 runtime Rolling net7.0-OSX-Release-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1744574 runtime Rolling net7.0-OSX-Release-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1744574 runtime Rolling net7.0-OSX-Release-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1744385 runtime PR 68583 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1744385 runtime PR 68583 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1744385 runtime PR 68583 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1744068 runtime PR 68695 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1744068 runtime PR 68695 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1744068 runtime PR 68695 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1742730 runtime PR 68674 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1742108 runtime PR 68332 net6.0-OSX-Debug-x64-CoreCLR_release-OSX.1015.Amd64.Open console.log runclient.py
1742108 runtime PR 68332 net6.0-OSX-Debug-x64-CoreCLR_checked-OSX.1015.Amd64.Open console.log runclient.py
1742108 runtime PR 68332 net6.0-OSX-Debug-x64-Mono_release-OSX.1015.Amd64.Open console.log runclient.py
1728986 runtime PR 67636 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728971 runtime PR 68288 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728971 runtime PR 68288 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728971 runtime PR 68288 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728898 runtime PR 68241 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728898 runtime PR 68241 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728898 runtime PR 68241 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728865 runtime PR 68285 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728865 runtime PR 68285 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728865 runtime PR 68285 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728841 runtime PR 68274 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728841 runtime PR 68274 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728841 runtime PR 68274 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728819 runtime PR 68283 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728808 runtime PR 68282 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728791 runtime PR 68281 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728791 runtime PR 68281 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728791 runtime PR 68281 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728743 runtime PR 68177 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728743 runtime PR 68177 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728743 runtime PR 68177 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728719 runtime PR 68270 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728653 runtime PR 67997 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728653 runtime PR 67997 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728653 runtime PR 67997 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728630 runtime PR 68275 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728630 runtime PR 68275 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728630 runtime PR 68275 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728577 runtime PR 68104 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728577 runtime PR 68104 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728577 runtime PR 68104 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728573 runtime PR 68273 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728573 runtime PR 68273 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728573 runtime PR 68273 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728533 runtime PR 67701 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728533 runtime PR 67701 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728533 runtime PR 67701 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728481 runtime PR 68271 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py
1728481 runtime PR 68271 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728481 runtime PR 68271 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728470 runtime PR 60236 net7.0-OSX-Debug-x64-CoreCLR_release-OSX.1200.Amd64.Open console.log runclient.py
1728470 runtime PR 60236 net7.0-OSX-Debug-x64-CoreCLR_checked-OSX.1200.Amd64.Open console.log runclient.py
1728470 runtime PR 60236 net7.0-OSX-Debug-x64-Mono_release-OSX.1200.Amd64.Open console.log runclient.py

Build Result Summary

Day Hit Count Week Hit Count Month Hit Count
1 1 17

Activity

  1. ghost added
    untriagedNew issue has not been triaged by the area owner
    on Apr 20, 2022
  2. danmoseley commented on Apr 20, 2022

    @danmoseley
    Contributor

    The earliest build listed above was 4/20/2022, 11:00:15 AM. I checked in my zip bug fix (not that I can see how it was related) at ~12 PST.

  3. elinor-fung commented on Apr 20, 2022

    @elinor-fung
    Member

    Expected: 3968 -> 7600, which is S_ISUID | S_ISGID | S_ISVTX
    Actual: 2944 -> 5600, which is S_ISUID | S_ISVTX

    Lots of hits today. Marking as blocking-clean-ci.

  4. added
    blocking-clean-ciBlocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms'
    on Apr 20, 2022
  5. danmoseley commented on Apr 20, 2022

    @danmoseley
    Contributor

    @dotnet/dnceng did anything change in the OSX 12 image?

    @eerhardt you recall this code -- any idea?

    this line may be relevant, but it suggests that we should expect these bits to be cleared?

    // S_ISUID, S_ISGID, and S_ISVTX bits. This matches unzip's default behavior.

  6. MattGal commented on Apr 20, 2022

    @MattGal
    Member

    @dotnet/dnceng did anything change in the OSX 12 image?

    @eerhardt you recall this code -- any idea?

    this line may be relevant, but it suggests that we should expect these bits to be cleared?

    // S_ISUID, S_ISGID, and S_ISVTX bits. This matches unzip's default behavior.

    Hi Dan! Can you comment on time? The only interesting thing to change here was moving from 12.0 to 12.3 a while back because the GA 12.0 kept timing out. That wasn't particularly recently though, so your time range would be useful to know.

  7. MattGal commented on Apr 20, 2022

    @MattGal
    Member

    @danmoseley I confirmed the update (12.0 -> 12.3 latest-at-the-time) was on 3/29, about 3 weeks ago. Beyond this, these machines have done nothing but execute test work items.

  8. danmoseley commented on Apr 21, 2022

    @danmoseley
    Contributor

    @eerhardt thoughts? does this pass on your mac hardware (I assume it's 12.3 or you can update it)

  9. danmoseley commented on Apr 21, 2022

    @danmoseley
    Contributor

    oh, he's out til Monday. I'll disable the test meantime (I should have done this already)

  10. added
    disabled-testThe test is disabled in source code against the issue
    and removed
    blocking-clean-ciBlocking PR or rolling runs of 'runtime' or 'runtime-extra-platforms'
    on Apr 22, 2022
  11. added this to the 7.0.0 milestone on May 3, 2022
  12. removed
    untriagedNew issue has not been triaged by the area owner
    on May 3, 2022
  13. carlossanlop commented on May 4, 2022

    @carlossanlop
    Contributor

    Also affecting the release/6.0 branch. I'm disabling the tests there too: #68867

    When this issue gets fixed, the fix needs to get backported to release/6.0.

  14. ghost added
    in-prThere is an active PR which will close this issue when it is merged
    on May 19, 2022
  15. eerhardt commented on May 19, 2022

    @eerhardt
    Member

    I finally got back to this. I've created #69583 to fix this issue.

    The problem, as far as I can tell, is that the macOS devices used in CI must have changed which group they run under, or somehow the user configuration on the machines changed. The tests were failing because they expected the S_ISGID bit to be set on the files, but that bit wasn't be set. Reading https://linux.die.net/man/3/chmod, it says:

    If the calling process does not have appropriate privileges, and if the group ID of the file does not match the effective group ID or one of the supplementary group IDs and if the file is a regular file, bit S_ISGID (set-group-ID on execution) in the file's mode shall be cleared upon successful return from chmod().

    So, what was happening here is that the test was calling chmod with S_ISGID being set, but the OS was clearing the bit. To fix this I changed the test to read the file mode after calling chmod and using that as the expected file mode. On "normal dev" unix environments (including my local macOS 12.3 machine), the bit isn't being cleared, and the tests pass successfully without modification. But to allow CI to work, the tests will now handle this case.

  16. carlossanlop commented on May 20, 2022

    @carlossanlop
    Contributor

    Thanks for the investigation, @eerhardt. Coincidentally, I still have to fix a bug in the tar tests related to chmod to make sure it is working properly, and after the fix I need to make sure they don't hit the same failure.

  17. added a commit that references this issue on May 20, 2022
    6069680
  18. ghost removed
    in-prThere is an active PR which will close this issue when it is merged
    on May 20, 2022
  19. ghost locked as resolved and limited conversation to collaborators on Jun 19, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions