Your message dated Sun, 19 Mar 2017 15:35:08 +0000 with message-id <[email protected]> and subject line Bug#847571: fixed in smarty-lexer 3.1.30+dfsg1-1.1 has caused the Debian Bug report #847571, regarding smarty3: lexing failed because a rule matched an empty string to be marked as done.
This means that you claim that the problem has been dealt with. If this is not the case it is now your responsibility to reopen the Bug report if necessary, and/or fix the problem forthwith. (NB: If you are a system administrator and have no idea what this message is talking about, this may indicate a serious mail system misconfiguration somewhere. Please contact [email protected] immediately.) -- 847571: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=847571 Debian Bug Tracking System Contact [email protected] with problems
--- Begin Message ---Package: smarty3 Version: 3.1.30-1 Severity: important After upgrade to 3.1.30 on Debian testing some templates failed to compile with the fatal error [:error] [pid 1203] [client 127.0.0.1:35140] PHP Fatal error: Uncaught Exception: Error: lexing failed because a rule matched an empty string. Input "0}\n ... state TAGBODY in /usr/share/php/smarty3/sysplugins/smarty_internal_templatelexer.php:566\nStack trace:\n#0 /usr/share/php/smarty3/sysplugins/smarty_internal_templatelexer.php(263): Smarty_Internal_Templatelexer->yylex3()\n#1 /usr/share/php/smarty3/sysplugins/smarty_internal_smartytemplatecompiler.php(109): Smarty_Internal_Templatelexer->yylex()\n#2 /usr/share/php/smarty3/sysplugins/smarty_internal_templatecompilerbase.php(404): Smarty_Internal_SmartyTemplateCompiler->doCompile('<!DOCTYPE html ...', true)\n#3 /usr/share/php/smarty3/sysplugins/smarty_internal_templatecompilerbase.php(335): Smarty_Internal_TemplateCompilerBase->compileTemplateSource(Object(Smarty_Internal_Template), false, NULL)\n#4 /usr/share/php/smarty3/sysplugins/smarty_template_compiled.php(199): Smarty_Internal_TemplateCompilerBase->compileTemplate(Object(Smarty_Internal_Template))\n#5 /usr/share/php/smarty3/sysplugins/smarty_template_compiled.php(98) in /usr/share/php/smarty3/sysplugins/smarty_internal_templatelexer.php on line 566 putting some trace in smarty_internal_templatelexer.php function yylex3() points to a problem with template code with a literal number 0 on the rhs of a test within {if} Error is reproduced with a clean install of Debian testing (Virtualbox) running CLI with a minimal test script <?php require_once '/usr/share/php/smarty3/Smarty.class.php'; $smarty=new Smarty(); $smarty->setTemplateDir('/home/www/test/template'); $smarty->setCompileDir('/home/www/test/compile'); $smarty->assign('foo', 0); $smarty->assign('data', 1); $smarty->display(__FILE__); __HALT_COMPILER(); ?> {if $foo==0} <p>{$data}</p> {/if} {$smarty.version} if $foo==0 is replaced by a literal other than 0 e.g. $foo==1 then compiling passes $foo==42-42 works not assigning a value to $foo makes no difference. Disabling opcache makes no difference. Once a template is compiled successfully with a value other than 0, changing back to literal 0 fails on first pass only. comparing file 'smarty_internal_templatelexer.php' extracted from github https://github.com/smarty-php/smarty/archive/v3.1.30.tar.gz extracted from debian testing http://http.debian.net/debian/pool/main/s/smarty3/smarty3_3.1.30.orig.tar.gz Files are identical extracted from github and either package installed or extracted from /var/cache/apt/archives/smarty3_3.1.30-1_all.deb Files differ After substituting function yylex3 in installed file with that from github test script compiles and correctly returns <p>1</p> 3.1.30 -- System Information: Debian Release: stretch/sid APT prefers testing APT policy: (500, 'testing') Architecture: amd64 (x86_64) Kernel: Linux 4.8.0-1-amd64 (SMP w/8 CPU cores) Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8) Shell: /bin/sh linked to /bin/dash Init: systemd (via /run/systemd/system) Versions of packages smarty3 depends on: ii php 1:7.0+46 ii php-common 1:46 ii php7.0 [php] 7.0.13-2 ii php7.0-cli [php-cli] 7.0.13-2 smarty3 recommends no packages. smarty3 suggests no packages. -- no debconf information
--- End Message ---
--- Begin Message ---Source: smarty-lexer Source-Version: 3.1.30+dfsg1-1.1 We believe that the bug you reported is fixed in the latest version of smarty-lexer, which is due to be installed in the Debian FTP archive. A summary of the changes between this version and the previous one is attached. Thank you for reporting the bug, which will now be closed. If you have further comments please address them to [email protected], and the maintainer will reopen the bug report if appropriate. Debian distribution maintenance software pp. Holger Levsen <[email protected]> (supplier of updated smarty-lexer package) (This message was generated automatically at their request; if you believe that there is a problem with it please contact the archive administrators by mailing [email protected]) -----BEGIN PGP SIGNED MESSAGE----- Hash: SHA512 Format: 1.8 Date: Sun, 19 Mar 2017 14:57:26 +0000 Source: smarty-lexer Binary: smarty-lexer Architecture: source Version: 3.1.30+dfsg1-1.1 Distribution: unstable Urgency: medium Maintainer: Mike Gabriel <[email protected]> Changed-By: Holger Levsen <[email protected]> Description: smarty-lexer - ${phpcomposer:description} Closes: 847571 Changes: smarty-lexer (3.1.30+dfsg1-1.1) unstable; urgency=medium . * Non-maintainer upload. * Apply upstream commits 54c249cf and ccaeeca3 to fix broken lexer breaking the template generator. (Closes: #847571) Thanks to Mike Gabriel for pointing out the upstream commits and equally thanks to Wolfgang Schweer and Tomasz Rybak for confirming the fix works. Checksums-Sha1: bb97b89c06735d7dffe1849ca49540271526934c 2037 smarty-lexer_3.1.30+dfsg1-1.1.dsc d01317ccd4ceab166fb7611227856bf0c1c68358 6424 smarty-lexer_3.1.30+dfsg1-1.1.debian.tar.xz 56e14f204986273dbc6a39aae2a6f840fd363a60 4748 smarty-lexer_3.1.30+dfsg1-1.1_source.buildinfo Checksums-Sha256: 31a54aea2f0a00328f4457bc653ef3935ce7ad976b7d0191004869840c0df4b6 2037 smarty-lexer_3.1.30+dfsg1-1.1.dsc 59704a3db3f17b7bb4effcec1d4b8a50ffaf0f0ae689baba69d615f1cf754e0a 6424 smarty-lexer_3.1.30+dfsg1-1.1.debian.tar.xz 0eefee32f9babbe347d3d565377429966e4faeb91c1449c4d70a08e2a8797579 4748 smarty-lexer_3.1.30+dfsg1-1.1_source.buildinfo Files: eb0a47e861d26f6f3db47a727f40255e 2037 web optional smarty-lexer_3.1.30+dfsg1-1.1.dsc 20c732f152fdc00a15442613c030a464 6424 web optional smarty-lexer_3.1.30+dfsg1-1.1.debian.tar.xz 3f7e3fbf8455a994684716940537f591 4748 web optional smarty-lexer_3.1.30+dfsg1-1.1_source.buildinfo -----BEGIN PGP SIGNATURE----- Version: GnuPG v1 iQIVAwUBWM6eMQkauFYGmqocAQq5PRAArzRv/lARXm83wL7PLVtjdllshbLh469X oGisQTQhFMl37NB9GcNLtPlsifC+YRGqF+Da/4b/fS0VV2Hck/ZfNJrwBo95s/5L sAG+bxKSJaWX8/6NjkEKY+x+meitsX1x9uwtrPoitA75YNtTIwjnoVCv564Qav/6 ER550RuCOwCfrc7fki4MB5yrfH3FoZYu9OsF3TG6e2CfFHlnlc7ODBVE4iVX+LTD Vo22v9OCLlvpEg4DPpR1FTcwSxyKnENrMEd+p90tQWX+LbenHF7J6EuLyw38btu6 gmmYPROzFdOKUW7xiz8NyngqwN1hz5W1lycQasbuem1p2uTWzf6XWrCtF0cF8szL Ke6J1UAhfN+kKiWwPONhcfSDJR5Nk7O9zH4HFmJoLXxnGGmkeQ7z3SY8CZpX4odj YhOIGjpSx187UirgqZfk9qI4e1iO8fszGxZdv7KyTDIL+psHMguYmm5e1FQKjbRI Iyg5K0cEL8INk/HaKb0sV+VA7AdZ0JQn2ia7GXiExBcW7YtS1SqQqCc2dL9BK/sd qts30/ARlPp09tkjz31sBXs1jrHtmIcPzIMe4CfN7DyLIManiS5i0x6uGHHwn8LE 4qnO28ZweAWofyTQo+3PYCXX78uf24VmeZe6MPGiIsKpa3dcR1gJMy+NeniN/Dlt D2IdyMUh26M= =6OTS -----END PGP SIGNATURE-----
--- End Message ---

