RivePlayer is not AoT compatible (Windows App SDK 1.6)
Chưa có ai nhận issue này.
Đánh giá
- Độ khó
- 5/5
- Thời gian dự kiến
- Hơn một tuần
- Mức phù hợp với người mới
- 30/100
- Loại issue
- Lỗi
- Độ rõ ràng
- Cần làm rõ
- Mức độ hoạt động
- Đình trệ
- Công nghệ
- csharp
- Lĩnh vực
- desktop, testing-qa
Hướng nghiên cứu
Bắt đầu với components/RivePlayer/tests/ExampleRivePlayerTestClass.cs, đặc biệt là ComplexAsyncLoadUIExampleWithoutDispatcherTest, và kiểm tra components/RivePlayer/src/RivePlayer.cs tại dòng 49. Sau đó đọc RiveSharp.RiveAPI.cs và hướng dẫn liên kết về khả năng tương tác native để hiểu lỗi AoT. Công việc được coi là hoàn tất khi các bài kiểm thử AoT của Windows App SDK 1.6+ có thể chạy mà không gặp DllNotFoundException đã được báo cáo và không còn cần phải vô hiệu hóa chúng.
Do mô hình lập chỉ mục viết ra từ nội dung của issue.
Mô tả
Seems like tests are failing as a result of some issue with RivePlayer on Microsoft.WindowsAppSdk 1.6-preview1+ with AoT enabled:
System.TypeInitializationException: The type initializer for 'RiveSharp.Factory' threw an exception. ---> System.DllNotFoundException: Unable to load DLL 'rive' or one of its dependencies: The specified module could not be found. (0x8007007E)
Stack Trace:
at RiveSharp.RiveAPI.Factory_RegisterDelegates(FactoryDelegates delegates)
at RiveSharp.Factory..cctor()
--- End of inner exception stack trace ---
at RiveSharp.Scene..ctor()
at CommunityToolkit.Labs.WinUI.Rive.RivePlayer..ctor() in /_/components/RivePlayer/src/RivePlayer.cs:line 49
at RivePlayerExperiment.Tests.ExampleRivePlayerTestClass.ComplexAsyncLoadUIExampleWithoutDispatcherTest() in D:\a\Labs-Windows\Labs-Windows\components\RivePlayer\tests\ExampleRivePlayerTestClass.cs:line 121
at RivePlayerExperiment.Tests.ExampleRivePlayerTestClass.<ComplexAsyncLoadUIExampleWithoutDispatcherTest_ExampleRivePlayerTestClass_Test>b__12_0() in /_/ProjectHeads/AllComponents/Tests.Wasdk/obj/x64/Release/net8.0-windows10.0.22621.0/win-x64/CommunityToolkit.Tooling.TestGen/CommunityToolkit.Tooling.TestGen.UIThreadTestMethodGenerator/ComplexAsyncLoadUIExampleWithoutDispatcherTest_ExampleRivePlayerTestClass.g.cs:line 15
Originally posted by @Arlodotexe in https://github.com/CommunityToolkit/Labs-Windows/issues/561#issuecomment-2305885605
It looks like this is happening because the Rive.RiveSharp package is using runtime marshalling to call the native binary under the hood, which isn't AoT/trim friendly.
This issue should only be present when using Wasdk 1.6+ with AoT enabled. Other platforms are unaffected, but NativeAoT is not compatible with runtime marshalling. For more information, see Native interoperability best practices.
Fixing this will require changes to the underlying library. To avoid blocking the toolkit as a whole, the tests will be disabled on Wasdk until the issue can be resolved.
- Ngôn ngữ chính
- C#
- Star
- 485
- Fork
- 89
- Merge trung bình
- 19 giờ 46 phút
- Pull request đã merge (30 ngày)
- 2
Chuẩn bị môi trường
Khởi chạy dev container của dự án ngay trên trình duyệt, bằng tài khoản GitHub của bạn.
- Không có Dockerfile hay tệp Docker Compose
- Không có mẫu pull request
- Đọc hướng dẫn đóng góp
Bắt đầu từ đâu
- Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
- Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
- Fork repository và làm thay đổi trên một nhánh.
- Mở pull request có tham chiếu số hiệu của issue.
Issue khác của CommunityToolkit/Labs-Windows
-
bug :bug:
Độ khó 1/5 1-3 giờ Mức phù hợp với người mới 80/100
CommunityToolkit/Labs-Windows#815 ·
-
bug :bug:
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 38/100
CommunityToolkit/Labs-Windows#816 ·
-
bug :bug:
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 55/100
CommunityToolkit/Labs-Windows#814 ·
-
experiment :test_tube:
Độ khó 4/5 3-5 ngày Mức phù hợp với người mới 48/100
CommunityToolkit/Labs-Windows#812 ·
-
ux :paintbrush:
Độ khó 3/5 1-2 ngày Mức phù hợp với người mới 52/100
CommunityToolkit/Labs-Windows#808 · 1 bình luận ·
Tất cả issue của CommunityToolkit/Labs-Windows
Issue tương tự
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 65/100
Maintainer thường phản hồi trong vòng 1 ngày
-
possible bug
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
-
Include host.wslc.internal in the HTTPS development certificateCó thể đã có người làm @afscrome đã nhận hôm nay. Đang mởarea-commandlinetools
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 70/100
dotnet/aspnetcore#70122 · 1 bình luận ·
Maintainer thường phản hồi trong vòng 1 ngày
-
:1st_place_medal: good first issue :cowboy_hat_face: refactor :roller_coaster: enhancement
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 68/100
ApplETS/Backend-Hello#78 ·
-
Độ khó 2/5 1-3 giờ Mức phù hợp với người mới 74/100
Maintainer thường phản hồi trong vòng 2 ngày