FFmpegBlazor icon indicating copy to clipboard operation
FFmpegBlazor copied to clipboard

[Bug] IJSUnmarshalledRuntime is obsolote in .NET 7

Open Ksdmg opened this issue 1 year ago • 3 comments

I have a .NET 7 project running blazor server side. When initializing the JSRuntime, an exception is thrown:

await FFmpegFactory.Init(Runtime); // throws System.InvalidCastException: 'Unable to cast object of type 'Microsoft.AspNetCore.Components.Server.Circuits.RemoteJSRuntime' to type 'Microsoft.JSInterop.IJSUnmarshalledRuntime'.'

I found this -> https://github.com/dotnet/AspNetCore.Docs/blob/main/aspnetcore/blazor/javascript-interoperability/import-export-interop.md#obsolete-javascript-interop-api

Ksdmg avatar Mar 05 '24 09:03 Ksdmg

It also seems to be completely removed in .NET 9.

BigBang1112 avatar Oct 20 '24 02:10 BigBang1112

I will mostly rewrite the current js interop code after .NET 9 RC2 release, hopefully they have some news regarding .net wasm threads.

sps014 avatar Oct 21 '24 17:10 sps014

I've been roughly following where the new Blazor goes and I think they delayed multithreading once again (like they delay half of the features as usual), and looking deeper it is indeed the reality: https://github.com/dotnet/aspnetcore/issues/17730#issuecomment-2059602250 (which is funny when I look into the readme history)

BigBang1112 avatar Oct 21 '24 21:10 BigBang1112

Closing this as I have removed IJSUnmarshalled API from source.

sps014 avatar Dec 02 '24 20:12 sps014