From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.text.pandoc/33412 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: "'William Lupton' via pandoc-discuss" Newsgroups: gmane.text.pandoc Subject: Re: How to resolve "WARNING: Undefined function 'Figure'"? Is there a workaround? Date: Tue, 28 Nov 2023 17:31:21 +0000 Message-ID: References: <84b364a6-bbfe-4c9b-b825-d0f52557229fn@googlegroups.com> Reply-To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="00000000000026047e060b39ca66" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35825"; mail-complaints-to="usenet@ciao.gmane.io" To: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-X-From: pandoc-discuss+bncBCS4HJ6WSAHBB6GHTCVQMGQENS4QUZA-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Tue Nov 28 18:31:42 2023 Return-path: Envelope-to: gtp-pandoc-discuss@m.gmane-mx.org Original-Received: from mail-lj1-f192.google.com ([209.85.208.192]) by ciao.gmane.io with esmtps (TLS1.3:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.92) (envelope-from ) id 1r81vy-00096e-5r for gtp-pandoc-discuss@m.gmane-mx.org; Tue, 28 Nov 2023 18:31:42 +0100 Original-Received: by mail-lj1-f192.google.com with SMTP id 38308e7fff4ca-2c737d1ba09sf44414831fa.1 for ; Tue, 28 Nov 2023 09:31:42 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1701192701; cv=pass; d=google.com; s=arc-20160816; b=gTLqAsb2NsEASur/AN+hn+paAeKYUe+PEHS4WXB/6Fr/0tKuXoHYU8MqXqiMkOoAhw chCB7MxSU2DIvjYvCL1cyB4bH6ltczgL+6x2bfXfV1usk9YT/v5fhtOfmdNV0Y60MdgA U+8xM+eqHFEHS+PpZNTdfpMfSeFSamVAV8t4SPeZcLFYRYO5JmwmsX6Q1WRx8l+q3s7s EDfzdifp1tTuiSnd7awZWg5N1VTSOZ+RIXiFXtrhqJjfLfxjywQDUlWCa4F0SCyOUlOK fy+hZ4ShXoSiBjBXmU1A7oXhDVESUhE5Q2MtIw+mGD+644EZV/K8Cu73KIcTxNbEtovR m+XQ== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to:to:subject:message-id:date :from:in-reply-to:references:mime-version:dkim-signature; bh=u/Ze8KxZh8ohPa5xYggrjzE77aM7cNJV6OYqUtZDgTM=; fh=m01AhCNo7xUywHldCVYouaJypLlN7JgtNYbImzBf4N4=; b=0d0ALko+9POA01Ixc/y8HAv/XhrlCHwrWUdqqfMJjO2Fq+ui9OQy9Klbj7HnlRGZMy pI3xmt304Xxg1xldqcX8zeb7w0KcMqdoqZjCL7o8SMHYSV4SLTaWBX/U17WrhzNXr+yA VYhega0wfX4fSCOFJfrnKBp/V/chax1qFnRcNkjKVu4H76uCbSq8C2YaE8cKyM8RE+Mz /Spt6xQMPHdoYYmU+b/FX2c1ADmlzyyvuPsthOQruCnMCi9a5ta613KPqeXF9yc46Z9Q bhODwld5VyKsExpTZd8x1HlIv9rAXjQajBRajsA1HrPnH5oT4VYVAcgYLru41l/4K39K BuPQ== ARC-Authentication-Results: i=2; gmr-mx.google.com; dkim=pass header.i=@broadband-forum.org header.s=google header.b=ZbtZCBKU; spf=pass (google.com: domain of wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org designates 2a00:1450:4864:20::631 as permitted sender) smtp.mailfrom=wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadband-forum.org DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlegroups.com; s=20230601; t=1701192701; x=1701797501; darn=m.gmane-mx.org; h=list-unsubscribe:list-subscribe:list-archive:list-help:list-post :list-id:mailing-list:precedence:reply-to :x-original-authentication-results:x-original-sender:to:subject :message-id:date:from:in-reply-to:references:mime-version:from:to:cc :subject:date:message-id:reply-to; bh=u/Ze8KxZh8ohPa5xYggrjzE77aM7cNJV6OYqUtZDgTM=; b=untA3lZ1guGg4s+8acpiiKgIFZcvJPSrXciUUl/pz10Baq5NbrjYUa4ERKaFDe4koZ HPfUAed+AoaCQ2C04cCTYr2BprfkcRtMQuqjkJ6tl672sJimGeqYPM5Q5bpx3b8k/LUn 1HsSX/trcT01Vp7JAp83FLrY7e3Yh7/I47nNcXDRp1W1FQKr/my64EXUqP6eFcOKrbLN 8swkunXGJdf/U2mIYMVI4i4j24wCkVu47wZlIIqm1yNqO8JpAJSM3QrQctSp6+d3XbKa +J3/R6+FTlaMPYxltm2wO4/qg2G+/9F1zjYYikxLPATDh++9yHBUrtmD9CS X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701192701; x=1701797501; 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-authentication-results:x-original-sender:to:subject :message-id:date:from:in-reply-to:references:mime-version :x-beenthere:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=u/Ze8KxZh8ohPa5xYggrjzE77aM7cNJV6OYqUtZDgTM=; b=fh1s5cWCwju9uDUgMgvXuScEmlW9fHYEHAyvNc3AgunOnRPIcekAAqQj7d2ncaN/01 wPoJBBEpT2/Wy4C1kocADgCBkrSfEcR2vxJszfWDAxKlcV6HJXXEpHFr3KAhraq75vK1 sa4fJpxO/bAGJebcoRxCPlu3O/qdQPGLbhjw8rKulCsiK//gHZdNLS7y0HrdsZ+sBIMU ljvVyrJ4rl1jX25iQl1Sz6kiPkp3Wauy522kpt24JYJJzZ/bdpSt+jz0A5oCFo0po+sF HWtKxf85ZBTI5 X-Gm-Message-State: AOJu0Yy8rjlBxmfqHmyZKjf64ITVowXhRypRerbjtaxq7ZoxeiVM9lKb ChtC4HecC3s6gMwwzJdiKOw= X-Google-Smtp-Source: AGHT+IGjy1ecezDaPI5/2SNm21o9rH/XYtu5FAHlwWPd50A+zAE1ELlUP5lTuXx6RzwENfiP+s8hbg== X-Received: by 2002:a05:651c:22f:b0:2c9:b95e:8694 with SMTP id z15-20020a05651c022f00b002c9b95e8694mr947778ljn.45.1701192700034; Tue, 28 Nov 2023 09:31:40 -0800 (PST) X-BeenThere: pandoc-discuss-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org Original-Received: by 2002:a2e:b0c1:0:b0:2c8:8814:8a90 with SMTP id g1-20020a2eb0c1000000b002c888148a90ls94583ljl.2.-pod-prod-02-eu; Tue, 28 Nov 2023 09:31:34 -0800 (PST) X-Received: by 2002:a2e:6e0e:0:b0:2c8:8c48:539c with SMTP id j14-20020a2e6e0e000000b002c88c48539cmr10838549ljc.2.1701192694211; Tue, 28 Nov 2023 09:31:34 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1701192694; cv=none; d=google.com; s=arc-20160816; b=N0vmpuqNcdNHSMDah+WxPe8EeGFIU8STXz2cjZ6LAr1ZrdE+EFiwXjQ9NeRhCuvGsn n3WC2RaXk0mKij1I0jg6tgPzL2m2JTK4QBt0Jzkw5UHcowobrStZudyiacjFhda9Zv2d 1vs+lSfuq/Psp5nYO0YtO51IWlG+YqWyWb7LUh8tWsogaDFmtiw1kzdg3VkATF4ol6Th W3gqOXX03N+zCZsv7Nz0h0AbGB/ETlp7pxtsWbUKn/ommWuLRZI8WA1GR27zIR1GjAo3 vborE1aM8BfuBzoK4Ikg/xXbxSrK5icl9mNBQJppB7kt2b0yOTAxgACmTA61qQBV1u8w 7Uqg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=to:subject:message-id:date:from:in-reply-to:references:mime-version :dkim-signature; bh=h8iJrRetmyM6nIiNazN61/6w+C/aMnOmlOydz3pFICw=; fh=m01AhCNo7xUywHldCVYouaJypLlN7JgtNYbImzBf4N4=; b=1IRqWK68D4cfs2x7nSf70upV7bWS6N4y35ZIXZJpf0iNXXvgnzUd5DvPNbgrq5UMm0 wGnTKT+0nUZidDA3T1iYOqZwad5kTBF+qjDL/JqW/bz3rwzlHPWbVmIpoYj0QyVRH48H Qei7kCmYsTXD1WM2r0eqOLLtTqHM2jWfiGlhKjmjCPaMxF7yG3KbuDjaa98Ivsh6A4Qo ChTJsC/NS2bfK+4DsaE2KiRzvHO5y4x3WBqo9y0NL62Q2tGHHrZDHOzWOdSsuIS+tEt3 6pdhyuzdp8MGecGH84qY95lRA5R0FrgNlvGqQd8CWnQ7JeJCJAPadq/apUOdIVSlMuJp MzNg== ARC-Authentication-Results: i=1; gmr-mx.google.com; dkim=pass header.i=@broadband-forum.org header.s=google header.b=ZbtZCBKU; spf=pass (google.com: domain of wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org designates 2a00:1450:4864:20::631 as permitted sender) smtp.mailfrom=wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadband-forum.org Original-Received: from mail-ej1-x631.google.com (mail-ej1-x631.google.com. [2a00:1450:4864:20::631]) by gmr-mx.google.com with ESMTPS id q191-20020a2e5cc8000000b002c9b23ce16fsi177169ljb.2.2023.11.28.09.31.34 for (version=TLS1_3 cipher=TLS_AES_128_GCM_SHA256 bits=128/128); Tue, 28 Nov 2023 09:31:34 -0800 (PST) Received-SPF: pass (google.com: domain of wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org designates 2a00:1450:4864:20::631 as permitted sender) client-ip=2a00:1450:4864:20::631; Original-Received: by mail-ej1-x631.google.com with SMTP id a640c23a62f3a-a011e9bf336so798160566b.3 for ; Tue, 28 Nov 2023 09:31:34 -0800 (PST) X-Received: by 2002:a17:907:1b0a:b0:a01:a56f:f882 with SMTP id mp10-20020a1709071b0a00b00a01a56ff882mr12894094ejc.34.1701192692788; Tue, 28 Nov 2023 09:31:32 -0800 (PST) In-Reply-To: <84b364a6-bbfe-4c9b-b825-d0f52557229fn-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org> X-Original-Sender: wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org X-Original-Authentication-Results: gmr-mx.google.com; dkim=pass header.i=@broadband-forum.org header.s=google header.b=ZbtZCBKU; spf=pass (google.com: domain of wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org designates 2a00:1450:4864:20::631 as permitted sender) smtp.mailfrom=wlupton-QSt+ys/nuMyEUIsrzH9SikB+6BGkLq7r@public.gmane.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadband-forum.org X-Original-From: William Lupton 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:33412 Archived-At: --00000000000026047e060b39ca66 Content-Type: text/plain; charset="UTF-8" The Figure element was added in 3.0: search https://pandoc.org/releases.html for "Support complex figures" for full details. So I think that your Confluence writer needs to be updated! I see that it has a CaptionedImage function and suspect that this will no longer be called, and that the needs-to-be-added Figure function will get called instead, but probably not with exactly the same arguments. Are you OK with hacking this? I don't mind having a go if not... let me know! On Tue, 28 Nov 2023 at 17:04, Klaus R. wrote: > Hi, > > To generate my documentation, I use a toolchain that generates a markdown > file from various sources, the last step is the generation of Confluence > HTML via Pandoc. Since Pandoc does not directly support Confluence HTML, I > use a patched version of > https://github.com/jpbarrette/pandoc-confluence-writer (patched because > the generated HTMl is not always quite correct and some features I need are > missing). This worked well for a long time, but after the last update (from > Pandoc 2.19.2 to 3.1.8) I got a series of warnings: > > > > *WARNING: Undefined function 'Figure'WARNING: Undefined function > 'Figure'...* > > and the HTML code for the images is completely missing. I tried Pandoc > 3.1.9, same result. Confusing: the Lua code of pandoc-confluence-writer > does not contain a call to a function named "Figure". Just to analyze the > problem, i tried custom-markdown.lua from > https://gist.github.com/tarleb/5a9c3fbfa47b0e6d3643efd8af2994b9 and i got: > > > *Error running Lua:custom-markdown.lua:19: No function to convert Figure > (Block)* > > What's going on? Is this a bug in Pandoc? Is there a workaround? > > At the moment I will be using version 2.19.2, but I would like to be able > to upgrade to newer versions of Pandoc. > > Minimal example: > > > > > > *# ExampleJust an example.![Fancy example](img/mypic.png){scale=70}* > > > Regards, > Klaus > > -- > 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/84b364a6-bbfe-4c9b-b825-d0f52557229fn%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/CAEe_xxg1bdy8nKFf1uY4NojPTxJgxTur-7Es5Y%2BrHMaXOtKeBA%40mail.gmail.com. --00000000000026047e060b39ca66 Content-Type: text/html; charset="UTF-8" Content-Transfer-Encoding: quoted-printable
The Figure element was added in 3.0: search=C2=A0https://pandoc.org/= releases.html for "Support complex figures" for full details.=

So I think that your Confluence writer needs to be upda= ted! I see that it has a=C2=A0CaptionedImage function and suspect that this= will no longer be called, and that the needs-to-be-added Figure function w= ill get called instead, but probably not with exactly the same arguments.

Are you OK with hacking this? I don't mind having= a go if not... let me know!

On Tue, 28 Nov 2023 at 17:04, Klaus= R. <k-rindfrey@g= mx.de> wrote:
Hi,

To generate my documentation, I use = a toolchain that generates a markdown file from various sources, the last s= tep is the generation of Confluence HTML via Pandoc. Since Pandoc does not = directly support Confluence HTML, I use a patched version of http= s://github.com/jpbarrette/pandoc-confluence-writer (patched because the= generated HTMl is not always quite correct and some features I need are mi= ssing). This worked well for a long time, but after the last update (from P= andoc 2.19.2 to 3.1.8) I got a series of warnings:

WARNING: Undef= ined function 'Figure'
WARNING: Undefined function 'Figure&#= 39;
...


and the HTML code for the images is completely missin= g. I tried Pandoc 3.1.9, same result. Confusing: the Lua code of pandoc-con= fluence-writer does not contain a call to a function named "Figure&quo= t;. Just to analyze the problem, i tried custom-markdown.lua from https://gist.github.com/tarleb/5a9c3fbfa47b0e6d3643efd8af2994b9= and i got:

Error running Lua:
custom-markdown.lua:19: No = function to convert Figure (Block)


What's going on? Is this = a bug in Pandoc? Is there a workaround?

At the moment I will be usin= g version 2.19.2, but I would like to be able to upgrade to newer versions = of Pandoc.

Minimal example:

# Example

Just an example.

![Fancy examp= le](img/mypic.png){scale=3D70}



<= div>Regards,
Klaus

--
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 pandoc-discuss+unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org.
To view this discussion on the web visit https= ://groups.google.com/d/msgid/pandoc-discuss/84b364a6-bbfe-4c9b-b825-d0f5255= 7229fn%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://group= s.google.com/d/msgid/pandoc-discuss/CAEe_xxg1bdy8nKFf1uY4NojPTxJgxTur-7Es5Y= %2BrHMaXOtKeBA%40mail.gmail.com.
--00000000000026047e060b39ca66--