OYIon / LiveSharp

Public repository for the LiveSharp project
96 stars 4 forks source link

Invalid instruction target ffffffeb #110

Closed warappa closed 3 years ago

warappa commented 3 years ago

Problem

If I add an EditForm in an if I get an Invalid instruction target ffffffeb error.

Repo

https://github.com/warappa/RepoLiveSharpUpdateFailsWithMatBlazor/tree/weird-il-error Branch: weird-il-error

Prerequisites

Steps

  1. Open in VS 2019 16.8.1
  2. Rebuilt whole Solution
  3. Set RepoLiveSharpUpdateFailsWithMatBlazor.Server as Startup Project
  4. Start LiveSharp Server
  5. Start Server project with F5
  6. Once loaded click in menu on Assets
  7. Exception as shown below is printed in the console
  8. Stop debugging
  9. In Assets.razor comment the whole line 6 (EditForm) out
  10. Rebuild solution (important!)
  11. Repeat steps 5-6
  12. No exception is shown in console
  13. Stop debugging
  14. Remove LiveSharp package from Client project
  15. Comment whole LiveSharp.dashboard.cs content out
  16. In Assets.razor undo commenting the whole line 6 out (= undo step 9)
  17. Rebuild solution (important!)
  18. Repeat steps 5-6
  19. No exception is shown in console

Exception

blazor.webassembly.js:1 crit: Microsoft.AspNetCore.Components.WebAssembly.Rendering.WebAssemblyRenderer[100]
      Unhandled exception rendering component: Error in RepoLiveSharpUpdateFailsWithMatBlazor.Client.Pages.Assets:RepoLiveSharpUpdateFailsWithMatBlazor.Client.Pages.Assets:BuildRenderTree (Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder) Invalid instruction target ffffffeb
System.Security.VerificationException: Error in RepoLiveSharpUpdateFailsWithMatBlazor.Client.Pages.Assets:RepoLiveSharpUpdateFailsWithMatBlazor.Client.Pages.Assets:BuildRenderTree (Microsoft.AspNetCore.Components.Rendering.RenderTreeBuilder) Invalid instruction target ffffffeb
   at Microsoft.AspNetCore.Components.ComponentBase.<.ctor>b__6_0(RenderTreeBuilder builder)
   at Microsoft.AspNetCore.Components.Rendering.ComponentState.RenderIntoBatch(RenderBatchBuilder batchBuilder, RenderFragment renderFragment)
   at Microsoft.AspNetCore.Components.RenderTree.Renderer.RenderInExistingBatch(RenderQueueEntry renderQueueEntry)
   at Microsoft.AspNetCore.Components.RenderTree.Renderer.ProcessRenderQueue()?

Another Exception in private project (source of the reduced repo)

: * Assertion at /__w/1/s/src/mono/mono/mini/interp/transform.c:6622, condition `<disabled>' not met

555639 @ dotnet.5.0.1.js:1
_emscripten_asm_const_int @ dotnet.5.0.1.js:1
wasm_logger @ dotnet.wasm:0xdc9ad
eglib_log_adapter @ dotnet.wasm:0x1930fe
monoeg_g_logstr @ dotnet.wasm:0x1081db
monoeg_g_logv_nofree @ dotnet.wasm:0x89e6e
monoeg_assertion_message @ dotnet.wasm:0x1109b
mono_assertion_message @ dotnet.wasm:0x815f
mono_assertion_message_disabled @ dotnet.wasm:0x56cf
get_in_offset @ dotnet.wasm:0x2dbda
emit_compacted_instruction @ dotnet.wasm:0x192aa4
generate_compacted_code @ dotnet.wasm:0x188dd0
generate @ dotnet.wasm:0x18907b
mono_interp_transform_method @ dotnet.wasm:0x31608
do_transform_method @ dotnet.wasm:0xd3578
interp_exec_method @ dotnet.wasm:0x51405
interp_runtime_invoke @ dotnet.wasm:0x12efff
mono_jit_runtime_invoke @ dotnet.wasm:0x118e5f
do_runtime_invoke @ dotnet.wasm:0x79d42
mono_runtime_try_invoke @ dotnet.wasm:0x12982
mono_runtime_invoke @ dotnet.wasm:0x10ec2b
mono_wasm_invoke_method @ dotnet.wasm:0x108e48
Module._mono_wasm_invoke_method @ dotnet.5.0.1.js:1
call_method @ dotnet.5.0.1.js:1
set_task_result @ dotnet.5.0.1.js:1
(anonymous) @ dotnet.5.0.1.js:1
Promise.then (async)
js_to_mono_obj @ dotnet.5.0.1.js:1
d.preRun.push.window.Blazor._internal.getSatelliteAssemblies @ blazor.webassembly.js:1
w @ blazor.webassembly.js:1
_mono_wasm_invoke_js_blazor @ dotnet.5.0.1.js:1
do_icall @ dotnet.wasm:0x194e58
do_icall_wrapper @ dotnet.wasm:0x79df9
interp_exec_method @ dotnet.wasm:0x44ad3
interp_runtime_invoke @ dotnet.wasm:0x12efff
mono_jit_runtime_invoke @ dotnet.wasm:0x118e5f
do_runtime_invoke @ dotnet.wasm:0x79d42
mono_runtime_invoke_checked @ dotnet.wasm:0xf65d
mono_runtime_try_invoke_array @ dotnet.wasm:0x10e831
ves_icall_InternalInvoke @ dotnet.wasm:0xed492
ves_icall_InternalInvoke_raw @ dotnet.wasm:0xecf57
do_icall @ dotnet.wasm:0x194de5
do_icall_wrapper @ dotnet.wasm:0x79df9
interp_exec_method @ dotnet.wasm:0x44ad3
interp_runtime_invoke @ dotnet.wasm:0x12efff
mono_jit_runtime_invoke @ dotnet.wasm:0x118e5f
do_runtime_invoke @ dotnet.wasm:0x79d42
mono_runtime_try_invoke @ dotnet.wasm:0x12982
mono_runtime_invoke @ dotnet.wasm:0x10ec2b
mono_wasm_invoke_method @ dotnet.wasm:0x108e48
Module._mono_wasm_invoke_method @ dotnet.5.0.1.js:1
call_method @ dotnet.5.0.1.js:1
(anonymous) @ dotnet.5.0.1.js:1
callEntryPoint @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
a @ blazor.webassembly.js:1
Promise.then (async)
u @ blazor.webassembly.js:1
a @ blazor.webassembly.js:1
Promise.then (async)
u @ blazor.webassembly.js:1
a @ blazor.webassembly.js:1
Promise.then (async)
u @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
r @ blazor.webassembly.js:1
g @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
n @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
(anonymous) @ blazor.webassembly.js:1
ionoy commented 3 years ago

Hi @warappa !

I'm trying to reproduce the issue with and I don't see the exception. Although, I'm using my own internal build which has some stuff rewritten. Are you still experiencing this issue?

warappa commented 3 years ago

Hi @ionoy, with LiveSharp 1.6.52 I can no longer reproduce this issue in my private project nor this repo! 👍

But in order to avoid the 2nd exception (condition <disabled> not met) in the repo(!), I had to manually delete %Temp%\LiveSharp and SolutionCache, although I updated (1.6.45-beta -> 1.6.52) and rebuilt everything. One thing I'm not 100% sure of is, if I restarted the LiveSharp Server. But if I - as an experienced user - am impeded by this, then a novice user will hit a roadblock. I think the Rebuild Solution should be the most any user have to do to ensure LiveSharp resyncs everthing necessary (even if LiveSharp server is still running during a rebuild).