runtime icon indicating copy to clipboard operation
runtime copied to clipboard

[wasm] asset loading for workers

Open pavelsavara opened this issue 3 years ago • 7 comments

  • move asset related logic to separate fileassets.ts
  • split logging code into separate file logging.ts
  • add dotnet.wasm and dotnet-crypto-worker.js to mono-config.json via WasmAppBuilder
  • moved readSymbolMapFile() call to startup.ts
  • fixed bug in setup_proxy_console() which didn't really copy the original log and error functions of the console and caused recursion on error.
  • moved init_crypto after mono_wasm_load_config in mono_wasm_pre_init_essential_async
  • added new resource type js-module-crypto and js-module-threads
  • changed the detection of blazor startup sequence to not be disabled by presence of config, but only by config.assets having some assembly in it.

Most of this changes were moved from https://github.com/dotnet/runtime/pull/73073 where is log of discussions about it

pavelsavara avatar Aug 05 '22 18:08 pavelsavara

Tagging subscribers to 'arch-wasm': @lewing See info in area-owners.md if you want to be subscribed.

Issue Details
  • move asset related logic to separate fileassets.ts
  • split logging code into separate file logging.ts
  • add dotnet.wasm and dotnet-crypto-worker.js to mono-config.json via WasmAppBuilder
  • moved readSymbolMapFile() call to startup.ts
  • fixed bug in setup_proxy_console() which didn't really copy the original log and error functions of the console and caused recursion on error.
  • moved init_crypto after mono_wasm_load_config in mono_wasm_pre_init_essential_async
  • added new resource type js-module-crypto and js-module-threads
  • changed the detection of blazor startup sequence to not be disabled by presence of config, but only by config.assets having some assembly in it.
Author: pavelsavara
Assignees: pavelsavara
Labels:

arch-wasm, area-System.Runtime.InteropServices.JavaScript

Milestone: 7.0.0

msftbot[bot] avatar Aug 05 '22 18:08 msftbot[bot]

/azp run runtime-wasm

pavelsavara avatar Aug 05 '22 18:08 pavelsavara

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Aug 05 '22 18:08 azure-pipelines[bot]

/azp run runtime-wasm

pavelsavara avatar Aug 06 '22 05:08 pavelsavara

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Aug 06 '22 05:08 azure-pipelines[bot]

Unfortunately the deadlock is still with us. Log

pavelsavara avatar Aug 06 '22 12:08 pavelsavara

You can run the tests a good bunch(30?) of times on helix, which can be done in one shot as we had discussed offline. It is helpful in finding similar issues.

I wonder if we should always do that for tests that depend on workers, on CI.

radical avatar Aug 06 '22 12:08 radical

/azp run runtime-wasm

pavelsavara avatar Aug 08 '22 09:08 pavelsavara

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Aug 08 '22 09:08 azure-pipelines[bot]

/azp run runtime-wasm

pavelsavara avatar Aug 09 '22 12:08 pavelsavara

Pull request contains merge conflicts.

azure-pipelines[bot] avatar Aug 09 '22 12:08 azure-pipelines[bot]

/azp run runtime-wasm

pavelsavara avatar Aug 09 '22 12:08 pavelsavara

Azure Pipelines successfully started running 1 pipeline(s).

azure-pipelines[bot] avatar Aug 09 '22 12:08 azure-pipelines[bot]

  • OSX issue is unrelated
  • Installer issue is unrelated: Log
  • debugger issue is https://github.com/dotnet/runtime/issues/72946 Log

pavelsavara avatar Aug 09 '22 16:08 pavelsavara

The wasm/debugger test failures are unrelated, and will be fixed by https://github.com/dotnet/runtime/pull/73524 .

radical avatar Aug 09 '22 16:08 radical

We should queue up the crypto deadlock fix right after this. If this happens to cause any issue with crypto, then it can be fixed in that PR.

radical avatar Aug 09 '22 16:08 radical