plotly / plotly/Plotly.NET

MissingMethodException running Chart.toSVGString using Plotly.Net.ImageExport

Offen
#361 1 Kommentar 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Dieses Issue hat noch niemand übernommen.

Vorherrschende Sprache
F#
Sterne
860
Forks
99
Ø Merge
22 Min.
Gemergte PRs (30 T.)
1

Beschreibung

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.

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Erste Schritte

  1. Lies das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreib ins Issue, dass du es übernimmst — das erspart doppelte Arbeit.
  3. Forke das Repository und arbeite in einem Branch.
  4. Öffne einen Pull Request, der die Issue-Nummer nennt.

Rechercherichtung

Beginnen Sie damit, die .NET 6-Anwendung bei Program.fs Zeile 44 zu reproduzieren, wo Chart.toSVGString aufgerufen wird, und untersuchen Sie anschließend den in der Stacktrace angezeigten Aufruf von Plotly.NET.ImageExport PuppeteerSharpRenderer. Vergleichen Sie die Versionen des PuppeteerSharp-Pakets und die dabei verwendete LaunchAsync-Signatur; erledigt ist es, wenn Chart.toSVGString ohne MissingMethodException abgeschlossen wird.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Bewertung

Tech-Stack
fsharp
Bereich
data-visualization
Issue-Typ
Bug
Schwierigkeit
4/5
Geschätzter Aufwand
3-5 Tage
Aktivitätsstatus
Veraltet
Klarheit
Größtenteils klar
Anfängerfreundlichkeit
25/100

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.