Ipynb writer: fixed carry-over of nbformat from metadata.
Previously we wrongly assumed it would be in a MetaString.
It's an a MetaInlines.
commit83ea529cf3cd410b598c3389a1edcc3d5593640c
authorJohn MacFarlane <jgm@berkeley.edu>
dateThu 28 Mar 2019, 17:12 (8 years ago)
parent9c7a57d
src/Text/Pandoc/Writers/Ipynb.hs+1−1
@@ -67,7 +67,7 @@ pandocToNotebook opts (Pandoc meta blocks) = do
6767 let nbformat =
6868 case (lookupMeta "nbformat" jupyterMeta,
6969 lookupMeta "nbformat_minor" jupyterMeta) of
70− (Just (MetaString "4"), Just (MetaString y)) ->
70+ (Just (MetaInlines [Str "4"]), Just (MetaInlines [Str y])) ->
7171 case safeRead y of
7272 Just z -> (4, z)
7373 Nothing -> (4, 5)