microsoft / ClearScript

A library for adding scripting to .NET applications. Supports V8 (Windows, Linux, macOS) and JScript/VBScript (Windows).
https://microsoft.github.io/ClearScript/
MIT License
1.74k stars 148 forks source link

Create instance of V8ScriptEngine crashes on macOS x64 NET 7.0 #489

Closed dany28 closed 1 year ago

dany28 commented 1 year ago

Reopen #343

Packages

  <ItemGroup>
    <PackageReference Include="Microsoft.ClearScript.V8" Version="7.3.7" />
    <PackageReference Include="Microsoft.ClearScript.V8.Native.win-x64" Version="7.3.7" />
    <PackageReference Include="Microsoft.ClearScript.V8.Native.osx-x64" Version="7.3.7" />
  </ItemGroup>

System: macOS Ventura 3.2.1 Processor: x64

Code:

var engine = new Microsoft.ClearScript.V8.V8ScriptEngine();

Runtime error:

12 == (*__error()).

Fix: After installing net5.0 the problem disappears

ClearScriptLib commented 1 year ago

Hi @dany28,

This looks like a duplicate of Issue #483. Please see here for an explanation and workarounds.

Good luck!

dany28 commented 1 year ago

Suggestion: https://github.com/microsoft/ClearScript/issues/483#issuecomment-1419248600

works for me

Thanks.