From mboxrd@z Thu Jan 1 00:00:00 1970 X-Msuck: nntp://news.gmane.io/gmane.comp.tex.context/68091 Path: news.gmane.org!not-for-mail From: Paul Menzel Newsgroups: gmane.comp.tex.context Subject: Re: t-filter: no table created when Unicode characters are included Date: Sun, 01 May 2011 12:48:12 +0200 Message-ID: <1304246892.23614.37.camel@mattotaupa> References: <1304111382.5256.20.camel@mattotaupa> <1304149025.5773.17.camel@mattotaupa> Reply-To: mailing list for ConTeXt users NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="===============2109511736==" X-Trace: dough.gmane.org 1304246918 24124 80.91.229.12 (1 May 2011 10:48:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 1 May 2011 10:48:38 +0000 (UTC) To: ntg-context@ntg.nl Original-X-From: ntg-context-bounces@ntg.nl Sun May 01 12:48:34 2011 Return-path: Envelope-to: gctc-ntg-context-518@m.gmane.org Original-Received: from balder.ntg.nl ([195.12.62.10]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1QGUCY-00068M-4x for gctc-ntg-context-518@m.gmane.org; Sun, 01 May 2011 12:48:34 +0200 Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 51CB8CAC84; Sun, 1 May 2011 12:48:33 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id I2mmSUtRZnTK; Sun, 1 May 2011 12:48:30 +0200 (CEST) Original-Received: from balder.ntg.nl (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 937B8CAC7F; Sun, 1 May 2011 12:48:30 +0200 (CEST) Original-Received: from localhost (localhost [127.0.0.1]) by balder.ntg.nl (Postfix) with ESMTP id 0B6E0CAC7F for ; Sun, 1 May 2011 12:48:29 +0200 (CEST) X-Virus-Scanned: Debian amavisd-new at balder.ntg.nl Original-Received: from balder.ntg.nl ([127.0.0.1]) by localhost (balder.ntg.nl [127.0.0.1]) (amavisd-new, port 10024) with LMTP id eDlISlY4cvCc for ; Sun, 1 May 2011 12:48:17 +0200 (CEST) Original-Received: from filter4-ams.mf.surf.net (filter4-ams.mf.surf.net [192.87.102.72]) by balder.ntg.nl (Postfix) with ESMTP id 8BAF8CAC7E for ; Sun, 1 May 2011 12:48:17 +0200 (CEST) Original-Received: from mail.gw90.de (mail.gw90.de [188.40.100.199]) by filter4-ams.mf.surf.net (8.14.3/8.14.3/Debian-5+lenny1) with ESMTP id p41AmE1Y014305 for ; Sun, 1 May 2011 12:48:16 +0200 Original-Received: from f053032032.adsl.alicedsl.de ([78.53.32.32] helo=[192.168.178.21]) by mail.gw90.de with esmtpsa (TLS1.0:RSA_AES_256_CBC_SHA1:32) (Exim 4.69) (envelope-from ) id 1QGUD8-0003b6-5J for ntg-context@ntg.nl; Sun, 01 May 2011 10:49:10 +0000 In-Reply-To: X-Mailer: Evolution 2.32.2 X-Bayes-Prob: 0.0001 (Score 0, tokens from: @@RPTN) X-CanIt-Geo: ip=188.40.100.199; country=DE; latitude=51.0000; longitude=9.0000; http://maps.google.com/maps?q=51.0000,9.0000&z=6 X-CanItPRO-Stream: uu:ntg-context@ntg.nl (inherits from uu:default, base:default) X-Canit-Stats-ID: 03ECaMevi - 1ba09d50534f - 20110501 X-Scanned-By: CanIt (www . roaringpenguin . com) on 192.87.102.72 X-BeenThere: ntg-context@ntg.nl X-Mailman-Version: 2.1.12 Precedence: list List-Id: mailing list for ConTeXt users List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: ntg-context-bounces@ntg.nl Errors-To: ntg-context-bounces@ntg.nl Xref: news.gmane.org gmane.comp.tex.context:68091 Archived-At: --===============2109511736== Content-Type: multipart/signed; micalg="pgp-sha1"; protocol="application/pgp-signature"; boundary="=-k/QykoRaTpMixzOhvT/V" --=-k/QykoRaTpMixzOhvT/V Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Am Samstag, den 30.04.2011, 11:10 -0400 schrieb Aditya Mahajan: > On Sat, 30 Apr 2011, Paul Menzel wrote: >=20 > > Am Freitag, den 29.04.2011, 18:13 -0400 schrieb Aditya Mahajan: > >> On Fri, 29 Apr 2011, Paul Menzel wrote: > > > >>> the filter module installed using > >>> does not work with the following example, which is also attached. > >>>=20 > >>> The output file `minimal-temp-rest.tex` is just empty. > >>> > >>> Replacing =C2=BB=CE=B1=C2=AB by =C2=BBa=C2=AB solves the problem. > >>> > >>> Running `filtercommand` in a terminal produces the *correct* output > >>> though and no empty file. > >>> > >>> Is that a known problem? > >> > >> No. The content of the file should not affect whether the filter is ru= n or > >> not. Can you add \traceexternalfilters on the top and check the output > >> (look for lines starting with t-filter). > > > >> The file works correctly on my machine. > > > > That is weired. > > > >> Which version of pandoc are you using? > > > > $ pandoc --version > > pandoc 1.5.1.1 >=20 > I am using 1.6 (the latest version is 1.8), but ... Version 1.8 is not yet uploaded to the Debian repositories since some Haskell packages are not yet available. See ticket #613256 [1] in the Debian BTS. > > As already written in my last mail. Executing the command directly work= s > > fine. >=20 > I really have no idea why this is happening. Pandoc does not give too man= y=20 > debugging options. A couple of things to check: >=20 > - What happens is you use pandoc -f rst -t native? (The updated example o= n=20 > github)? The output file is also empty. Running the command from console works again. > - If that fails, then try a simple rst file with a unicode letter (no=20 > table)? The output file is still empty. $ pandoc -f rst -t native -o rest-temp-rest.tex rest-temp-rest.tmp $ more rest-temp-rest.t{mp,ex} :::::::::::::: rest-temp-rest.tmp :::::::::::::: =CE=B1 :::::::::::::: rest-temp-rest.tex :::::::::::::: Pandoc (Meta {docTitle =3D [], docAuthors =3D [], docDate =3D []}) [ Para [Str "\945"] ] =20 =20 $ Is the =CE=B1 also encoded by `Str "\945"` in your setup? > - If that also fails, then a simple markdown file with a unicode letter. That fails too. $ more rest-temp-rest.tex $ pandoc -f markdown -t native -o rest-temp-rest.tex rest-temp-rest= .tmp $ more rest-temp-rest.t{mp,ex} :::::::::::::: rest-temp-rest.tmp :::::::::::::: =CE=B1 :::::::::::::: rest-temp-rest.tex :::::::::::::: Pandoc (Meta {docTitle =3D [], docAuthors =3D [], docDate =3D []}) [ Para [Str "\945"] ] =20 =20 $ > - If that also fails, then some other program that reads a file and write= s=20 > its contents to another file. Usinng the following \defineexternalfilter [rest] [filter=3D{cat \externalfilterinputfile\space | tee \externalfilt= eroutputfile}] works. $ more rest-temp-rest.t{mp,ex} :::::::::::::: rest-temp-rest.tmp :::::::::::::: =CE=B1 :::::::::::::: rest-temp-rest.tex :::::::::::::: =CE=B1 > - Manually execute the shell command from inside ConTeXt using > \ctxlua{os.execute("....")}. This does not work either. $ more tests/rest.tex % LM does not appear to have Greek letters in unicode slots \setupbodyfont[times] =20 \starttext Start. =20 \ctxlua{os.execute("pandoc -f rst -t context -o rest-temp-rest.tex = rest-temp-rest.tmp")} \stoptext $ context tests/rest.tex $ more rest-temp-rest.t{mp,ex} :::::::::::::: rest-temp-rest.tmp :::::::::::::: =CE=B1 :::::::::::::: rest-temp-rest.tex :::::::::::::: $ > Also, what OS you are on? I am using Debian Sid/unstable. > > $ pandoc -f rst -t context -o rest-temp-rest.tex rest-temp-rest.= tmp > > $ more rest-temp-rest.t*:::::::::::::: > > rest-temp-rest.tex > > :::::::::::::: > > \placetable[here]{none} > > \starttable[|l|l|] > > \HL > > \NC test > > \NC table > > \NC\AR > > \HL > > \NC =CE=B1 > > \NC b > > \NC\AR > > \NC c > > \NC d > > \NC\AR > > \HL > > \stoptable > > :::::::::::::: > > rest-temp-rest.tmp > > :::::::::::::: > > =3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=3D > > test table > > =3D=3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D=3D > > =CE=B1 b > > c d > > =3D=3D=3D=3D=3D=3D=3D=3D =3D=3D=3D=3D=3D=3D=3D=3D >=20 > Since the .tex file is created, it means that the filter module is runnin= g=20 > correctly. It is calling pandoc with the right options, and pandoc is=20 > creating an empty rest-temp-rest.tex file. Now I have no idea why that= =20 > file is empty. IIRC, pandoc sometimes misbehaves due to locale settings= =20 > (but I don't see why locale should be different when a program is run fro= m=20 > inside context then when it is run from a shell). I am using the following locale. $ locale LANG=3Dde_DE.UTF-8 LC_CTYPE=3D"de_DE.UTF-8" LC_NUMERIC=3D"de_DE.UTF-8" LC_TIME=3D"de_DE.UTF-8" LC_COLLATE=3D"de_DE.UTF-8" LC_MONETARY=3D"de_DE.UTF-8" LC_MESSAGES=3D"de_DE.UTF-8" LC_PAPER=3D"de_DE.UTF-8" LC_NAME=3D"de_DE.UTF-8" LC_ADDRESS=3D"de_DE.UTF-8" LC_TELEPHONE=3D"de_DE.UTF-8" LC_MEASUREMENT=3D"de_DE.UTF-8" LC_IDENTIFICATION=3D"de_DE.UTF-8" LC_ALL=3D > I am stymied. Well, I would say to not waste your time any longer and to suspect Pandoc at fault here. If a newer Pandoc version is available in the Debian archive I can retest to check the Pandoc version as the possible culprit. Thank you very much for your help, Paul [1] http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=3D613256 --=-k/QykoRaTpMixzOhvT/V Content-Type: application/pgp-signature; name="signature.asc" Content-Description: This is a digitally signed message part -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) iEYEABECAAYFAk29OmwACgkQPX1aK2wOHVg/qACggEWim8Gha41AWS90xXrAteL2 +tAAn25Tq7bwpsezwnu+LD0sJAXFm/Gf =pmjv -----END PGP SIGNATURE----- --=-k/QykoRaTpMixzOhvT/V-- --===============2109511736== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline ___________________________________________________________________________________ If your question is of interest to others as well, please add an entry to the Wiki! maillist : ntg-context@ntg.nl / http://www.ntg.nl/mailman/listinfo/ntg-context webpage : http://www.pragma-ade.nl / http://tex.aanhet.net archive : http://foundry.supelec.fr/projects/contextrev/ wiki : http://contextgarden.net ___________________________________________________________________________________ --===============2109511736==--