fsprojects / FSharp.Formatting

F# tools for generating documentation (Markdown processor and F# code formatter)
https://fsprojects.github.io/FSharp.Formatting/
Other
464 stars 155 forks source link

fsdocs does not generate correct code cell metadata for .ipynb #809

Closed nhirschey closed 1 year ago

nhirschey commented 1 year ago

Dotnet interactive expects specific metadata in an F# notebook. This has evolved over time, and we need to update fsdocs ipynb output to match what they currently expect. See for example https://github.com/dotnet/interactive/issues/2685

I reported the issue in the dotnet/interactive repo a few weeks ago, and they fixed it. But now it's broken again as of ths week's dotnet interactive. We should really make fsdocs output the metadata that dotnet interactive expects to help avoid breakages like this.

When the metadata is not correct, sometimes polyglot notebooks think an F# cell is C#. With correct metadata, this will not happen.