plotly / plotly/Plotly.NET

MissingMethodException running Chart.toSVGString using Plotly.Net.ImageExport

未关闭
#361 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

主要语言
F#
星标
860
派生
99
平均合并
22 分钟
30 天内合并 PR
1

描述

Calling Chart.toSVGString gives me:

Unhandled exception. System.MissingMethodException: Method not found: 'System.Threading.Tasks.Task`1<PuppeteerSharp.Browser> PuppeteerSharp.Puppeteer.LaunchAsync(PuppeteerSharp.LaunchOptions, Microsoft.Extensions.Logging.ILoggerFactory)'.
   at <StartupCode$Plotly-NET-ImageExport>.$PuppeteerSharpRenderer.clo@83-16.Invoke(Unit unitVar)
   at Microsoft.FSharp.Control.AsyncPrimitives.CallThenInvoke[T,TResult](AsyncActivation`1 ctxt, TResult result1, FSharpFunc`2 part2) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 510
   at Microsoft.FSharp.Control.Trampoline.Execute(FSharpFunc`2 firstAction) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 112
--- End of stack trace from previous location ---
   at Microsoft.FSharp.Control.AsyncResult`1.Commit() in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 454
   at Microsoft.FSharp.Control.AsyncPrimitives.QueueAsyncAndWaitForResultSynchronously[a](CancellationToken token, FSharpAsync`1 computation, FSharpOption`1 timeout) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 1140
   at Microsoft.FSharp.Control.AsyncPrimitives.RunSynchronously[T](CancellationToken cancellationToken, FSharpAsync`1 computation, FSharpOption`1 timeout) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 1167
   at Microsoft.FSharp.Control.FSharpAsync.RunSynchronously[T](FSharpAsync`1 computation, FSharpOption`1 timeout, FSharpOption`1 cancellationToken) in D:\a\_work\1\s\src\FSharp.Core\async.fs:line 1511
   at <StartupCode$myApp>.$Program.main@() in C:\Users\altaria\fsharp\Valueline\myApp\Program.fs:line 44

My code snippet:

// Api.chart is a GenericChart
open Giraffe.ViewEngine
let chartView = Api.chart |> Chart.toSVGString (Width = 800, Height = 600) |> Text

It looks like there's some issue calling a Puppeteer function?
I am on .NET 6 and running dotnet watch. I've tried PuppeteerSharp version 8.0.0 and 6.0.0 with no success.

贡献指南

这个仓库没有索引到贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

调研方向

首先,在调用 Chart.toSVGString 的 Program.fs 第 44 行重现 .NET 6 应用程序,然后检查堆栈跟踪中显示的 Plotly.NET.ImageExport PuppeteerSharpRenderer 调用。比较所涉及的 PuppeteerSharp 包版本和 LaunchAsync 签名;当 Chart.toSVGString 在没有 MissingMethodException 的情况下完成时,即表示完成。

由索引模型根据 Issue 内容生成。

评估

技术栈
fsharp
领域
data-visualization
Issue 类型
缺陷
难度
4/5
预计耗时
3-5 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
25/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。