From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/31364 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Harsh Donga Newsgroups: gmane.text.pandoc Subject: Re: Exception handling at writer end Date: Mon, 12 Sep 2022 03:37:23 -0700 (PDT) Message-ID: <55202b0f-9aa0-4182-bc74-193fd48af65an@googlegroups.com> References: Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_Part_726_1701576911.1662979043091" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="582"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss Original-X-From: pandoc-discuss+bncBD75NRVM24GBBZEX7SMAMGQEI3EOFPI-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mon Sep 12 12:37:27 2022 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-qk1-f190.google.com ([209.85.222.190]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1oXgoh-000AYb-8A for gtp-pandoc-discuss@m.gmane-mx.org; Mon, 12 Sep 2022 12:37:27 +0200 Original-Received: by mail-qk1-f190.google.com with SMTP id bj2-20020a05620a190200b006bba055ab6esf6957163qkb.12 for ; Mon, 12 Sep 2022 03:37:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :sender:from:to:cc:subject:date; bh=DW/SwkzgHuE8V8vfa352O/Aph9gS7zsc3bAkMzuo5Ks=; b=oxjA0teHUp7S3kabyesQ6wde4A45KDaGN5lrIXTRBxdsIzxyxqCvQZgEnRVZeINiFt 8MqVV7KsJ7iNFPZZvE42NJkP66puXNo1Q6Y2CgoRSS4tKpjWeOpXxX0yTpowvL3ZgK5O rOFrvRZ7ek7L1X4PX5hWAcu3nUCtLeULkVbe28ke1ccYEeFiKiQsd4tMtqwxYOv/V5/s 1XiVlgg1hFqJ7Zp8KtE97kTM2QOcWy9pW5F/I+7Rt8ugPqHPJBotEKpZKezRxKQBewBm AC/QGCuAlzaGAYMmQSJBAX0vU4cWvqjZ/rj76UbxKAHwU8cvjwWbkddp89QMJzczSgj8 Zbbg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=inclusivestem-org.20210112.gappssmtp.com; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:x-original-sender :mime-version:subject:references:in-reply-to:message-id:to:from:date :from:to:cc:subject:date; bh=DW/SwkzgHuE8V8vfa352O/Aph9gS7zsc3bAkMzuo5Ks=; b=mwIGZxiJHNTQYi+vugQFebxWppjjZLV/ehALbJPvyondzzFxbsMczcGU8Ga6+vlUIB iRBIaQ+975bRv4hBSl5rlVvYVbVpVu5ec/ciLBd9wJQeFByDV88ISjCLaQ708E/J4oZh oTrr7KPTrUxutE7JOkNUSgfB78V9Sko7W0z4kaKFTREkvcH7unnLF7ze1nXNwnupeItX 56zWujKrac3nHZC7/6VRIh73FNNmsubMkBF0e58tcSoTWcF43UHQ5v38agxHMgHhfP1h d+1cT97h5W58FWjU5I2f/Q3F9jhKIGxWoiaAjiSNlAbXSTcjrj55T+NjP+ydWj/xTAkF t/Mw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :x-spam-checked-in-group:list-id:mailing-list:precedence:reply-to :x-original-sender:mime-version:subject:references:in-reply-to :message-id:to:from:date:x-gm-message-state:sender:from:to:cc :subject:date; bh=DW/SwkzgHuE8V8vfa352O/Aph9gS7zsc3bAkMzuo5Ks=; b=jSj5wvqkDWWi30aV8a552h0/2kq6eo0Be4NJ8hDLC7Y+dYItqe6arYy4ZAF3IfpzTV rDYeYeBTh9opjoG3py4ApT4XbADLSVl1cLeqYPNkl7i6eihwk++PzctgLvucKLJ1IY6l K/JSZnDUHK6758uIbi/lMR2XB45lMIFuE9bGSRO4bOwKU1SiCPAV8m0wrBHhphDwhipY t1r1YMW1e9xXwl1hVrcBSX6I/qk2oLtqv/XohIPBcVahgu4r2LUb7gNIPPzndkClup4p r1L0kG7UMqH3FIYx8lx2r/XtVL/Yy5ECGaa0xYo7UjZHtRzw2Uzxl0c1g7ioqgGkgBnn N27w== Original-Sender: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org X-Gm-Message-State: ACgBeo1s/IT06z1mw91abp8/K3SdnzCCYIilF7jUGQECT9x4xTUm14Ku GXgZ8A5S0W5skvXTL7PDajM= X-Google-Smtp-Source: AA6agR6NHc841nST8gwRqY2LyymFuZhjoBb1uTb8KQjXDfCW7pkeg1LXtCsrtAS9ipN+TVXxSX+1Fw== X-Received: by 2002:a05:620a:1432:b0:6cd:4de8:4033 with SMTP id k18-20020a05620a143200b006cd4de84033mr10269592qkj.6.1662979046178; Mon, 12 Sep 2022 03:37:26 -0700 (PDT) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:ae9:ec14:0:b0:6c6:f442:249d with SMTP id h20-20020ae9ec14000000b006c6f442249dls6916575qkg.10.-pod-prod-gmail; Mon, 12 Sep 2022 03:37:23 -0700 (PDT) X-Received: by 2002:a05:620a:3729:b0:6ce:4711:8137 with SMTP id de41-20020a05620a372900b006ce47118137mr984519qkb.720.1662979043747; Mon, 12 Sep 2022 03:37:23 -0700 (PDT) In-Reply-To: X-Original-Sender: harsh-7+aFW328pE6p1wGUEcWPqti2O/JbrIOy@public.gmane.org Precedence: list Mailing-list: list pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org; contact pandoc-discuss+owners-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org List-ID: X-Google-Group-Id: 1007024079513 List-Post: , List-Help: , List-Archive: , List-Unsubscribe: , Xref: news.gmane.io gmane.text.pandoc:31364 Archived-At: ------=_Part_726_1701576911.1662979043091 Content-Type: multipart/alternative; boundary="----=_Part_727_8134063.1662979043091" ------=_Part_727_8134063.1662979043091 Content-Type: text/plain; charset="UTF-8" There are several cases, let's say here i am trying to make a BulletList but insert a heading object in between (out of structure) (Please refer first heading object inside bulletlist) It does not conform to : https://hackage.haskell.org/package/pandoc-types-1.22/docs/Text-Pandoc-Definition.html#t:Block (BulletList [[Block ]]) My intention to ask the question is if i can skip this element and process the rest? PFA : synthetically made Pandoc AST On Monday, 12 September 2022 at 15:55:00 UTC+5:30 fiddlosopher wrote: > Generally this shouldn't happen; writers should be able to handle > arbitrary ASTs. > So let us know the particulars. Give a short example sufficient to > reproduce the issue you're seeing. > > > On Sep 12, 2022, at 11:28 AM, Harsh Donga > wrote: > > > > Hey folks, > > > > Context : I am trying to convert Pandoc AST to HTML > > > > I would like to know if there is any exception handling done if let's > say a particular block in Pandoc AST is erroneous (wrongly structured or > placed). > > For now, pandoc command (pandoc -t html pandoc.json -o pandoc.html), > returns > > err at block[x][y] > > That is the whole conversion fails. > > > > Can that particular element be skipped or something else can be done? > > > > > > Thanks in advance! > > Regards, > > Harsh > > > > -- > > You received this message because you are subscribed to the Google > Groups "pandoc-discuss" group. > > To unsubscribe from this group and stop receiving emails from it, send > an email to pandoc-discus...-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org > > To view this discussion on the web visit > https://groups.google.com/d/msgid/pandoc-discuss/ab7b37d0-be67-4e93-8298-31f7069fe2a8n%40googlegroups.com > . > > -- You received this message because you are subscribed to the Google Groups "pandoc-discuss" group. To unsubscribe from this group and stop receiving emails from it, send an email to pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/55202b0f-9aa0-4182-bc74-193fd48af65an%40googlegroups.com. ------=_Part_727_8134063.1662979043091 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable There are several cases, let's say here i am trying to make a BulletList bu= t insert a heading object in between (out of structure) (Please refer first= heading object inside bulletlist)
It does not conform to : https://hackage.haskell.org/package/pandoc-types-= 1.22/docs/Text-Pandoc-Definition.html#t:Block (BulletList [[Block]])<= br>
My intention to ask the question is if i can skip this element and = process the rest?

PFA : synthetically made Pandoc = AST

On Monday, 12 September 2022 at 15:55:00 UTC+5:30 fiddlosop= her wrote:
Ge= nerally this shouldn't happen; writers should be able to handle arbitra= ry ASTs.
So let us know the particulars. Give a short example sufficient to rep= roduce the issue you're seeing.

> On Sep 12, 2022, at 11:28 AM, Harsh Donga <ha...-7+aFW328pE6p1wGUEcWPqti2O/JbrIOy@public.gmane.org> wrote:
>=20
> Hey folks,
>=20
> Context : I am trying to convert Pandoc AST to HTML
>=20
> I would like to know if there is any exception handling done if le= t's say a particular block in Pandoc AST is erroneous (wrongly structur= ed or placed).
> For now, pandoc command (pandoc -t html pandoc.json -o pandoc.html= ), returns=20
> err at block[x][y]
> That is the whole conversion fails.
>=20
> Can that particular element be skipped or something else can be do= ne?
>=20
>=20
> Thanks in advance!
> Regards,
> Harsh
>=20
> --=20
> You received this message because you are subscribed to the Google= Groups "pandoc-discuss" group.
> To unsubscribe from this group and stop receiving emails from it, = send an email to pandoc-discus..= .@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/pandoc-discuss/ab7b37d= 0-be67-4e93-8298-31f7069fe2a8n%40googlegroups.com.

--
You received this message because you are subscribed to the Google Groups &= quot;pandoc-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an e= mail to pand= oc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https://groups.google.com/d= /msgid/pandoc-discuss/55202b0f-9aa0-4182-bc74-193fd48af65an%40googlegroups.= com.
------=_Part_727_8134063.1662979043091-- ------=_Part_726_1701576911.1662979043091 Content-Type: application/json; name=outPandoc.json Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename=outPandoc.json X-Attachment-Id: da756a01-b19c-4581-9375-c1eabf070f61 Content-ID: { "pandoc-api-version": [ 1, 22 ], "meta": {}, "blocks": [ { "t": "BulletList", "c": [ { "t": "Header", "c": [ 1, [ "2099f074", [], [] ], [ { "t": "Link", "c": [ [ "3eb0591f", [], [] ], [ { "t": "Span", "c": [ [ "f25c60fd", [], [] ], [ { "t": "Str", "c": "Preface" }, { "t": "Space" }, { "t": "Str", "c": "1" }, { "t": "Space" } ] ] } ], [ "", "" ] ] }, { "t": "Span", "c": [ [ "da39a3ee", [], [] ], [] ] } ] ] }, [ { "t": "Plain", "c": [ { "t": "Span", "c": [ [ "a4c79909", [], [] ], [ { "t": "Str", "c": "Purpose" }, { "t": "Space" }, { "t": "Str", "c": "and" }, { "t": "Space" }, { "t": "Str", "c": "Intended" }, { "t": "Space" }, { "t": "Str", "c": "Audience" }, { "t": "Space" }, { "t": "Str", "c": "1" }, { "t": "Space" } ] ] } ] } ], [ { "t": "Plain", "c": [ { "t": "Span", "c": [ [ "457a4a74", [], [] ], [ { "t": "Str", "c": "Contents" }, { "t": "Space" }, { "t": "Str", "c": "1" }, { "t": "Space" } ] ] } ] } ], [ { "t": "Plain", "c": [ { "t": "Span", "c": [ [ "ec05c4cc", [], [] ], [ { "t": "Str", "c": "Acknowledgements1" }, { "t": "Space" } ] ] } ] } ], [ { "t": "Plain", "c": [ { "t": "Span", "c": [ [ "ef206426", [], [] ], [ { "t": "Str", "c": "Additional" }, { "t": "Space" }, { "t": "Str", "c": "Resources" }, { "t": "Space" } ] ] } ] } ] ] }, { "t": "Para", "c": [ { "t": "Span", "c": [ [ "2b92dde0", [], [] ], [ { "t": "Str", "c": "2008" }, { "t": "Space" }, { "t": "Str", "c": "Adobe" }, { "t": "Space" }, { "t": "Str", "c": "Systems" }, { "t": "Space" }, { "t": "Str", "c": "Incorporated." }, { "t": "Space" }, { "t": "Str", "c": "All" }, { "t": "Space" }, { "t": "Str", "c": "rights" }, { "t": "Space" }, { "t": "Str", "c": "reserved." }, { "t": "Space" } ] ] } ] } ] } ------=_Part_726_1701576911.1662979043091--