Skip to content

[WASM] Environment.UserName raises "not supported" exception #38164

Description

@safern

Update: UserName now fails with System.IO.IOException : Not supported

This is causing System.Runtime.Extensions.Tests to crash.

Crashes with:

Details ``` at 205708 (dotnet.js:1858:32) at _emscripten_asm_const_iii (dotnet.js:1863:27) at wasm_logger (:wasm-function[7791]:0x1f3d0d) at eglib_log_adapter (:wasm-function[6303]:0x1abc50) at monoeg_g_logstr (:wasm-function[7225]:0x1ced8d) at monoeg_g_logv_nofree (:wasm-function[7223]:0x1cecb4) at monoeg_g_logv (:wasm-function[7222]:0x1cec11) at monoeg_g_log (:wasm-function[7226]:0x1ceded) at getpwuid_r (:wasm-function[1131]:0x6e9e5) at SystemNative_GetPwUidR (:wasm-function[7726]:0x1effbc) ```

I guess this API should throw PNSE in WASM?

Will disable the tests against this issue in the meantime.

cc: @steveisok @lewing @marek-safar @akoeplinger

Activity

  1. akoeplinger commented on Jun 19, 2020

    @akoeplinger
    Member

    Looks like on Xamarin iOS/Android we returned a dummy "somebody" string from Environment.UserName.

  2. added this to the 5.0.0 milestone on Jun 22, 2020
  3. removed
    untriagedNew issue has not been triaged by the area owner
    on Jun 22, 2020
  4. akoeplinger commented on Jun 23, 2020

    @akoeplinger
    Member

    #38256 fixed the crash but we're still reporting System.IO.IOException : Not supported from the property so we still need to fix that.

    We should probably return the same dummy value that we return for Xamarin.iOS/Android.

  5. changed the title [-][WASM] Environment.UserName crashes on wasm[/-] [+][WASM] Environment.UserName raises "not supported" exception[/+] on Jun 23, 2020
  6. safern commented on Jun 23, 2020

    @safern
    MemberAuthor

    Also, the test should be re-enabled or skipped without ActiveIssue before we close the issue.

    [ActiveIssue("https://github.com/dotnet/runtime/issues/38164", TestPlatforms.Browser)]

  7. ghost locked as resolved and limited conversation to collaborators on Dec 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions