GNU bug report logs - #49910
[website] script generating POT files broken with guile@3.0.7

Previous Next

Package: guix;

Reported by: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>

Date: Fri, 6 Aug 2021 10:55:01 UTC

Severity: normal

Done: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 49910 in the body.
You can then email your comments to 49910 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#49910; Package guix. (Fri, 06 Aug 2021 10:55:01 GMT) Full text and rfc822 format available.

Acknowledgement sent to "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>:
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Fri, 06 Aug 2021 10:55:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>
To: bug-guix <at> gnu.org
Subject: [website] script generating POT files broken with guile <at> 3.0.7
Date: Fri, 6 Aug 2021 12:53:44 +0200
Hello Guix!

In the guix-artwork.git repo, the pot file generation
(scripts/sexp-xgettext.scm as described in the file i18n-howto) in the
website is broken since guile <at> 3.0.7.  Old guile <at> 3.0.2 works.

The issue is at the end of the procedure in the call to (read) within
token->string-symbol-or-keyw, specifically

guile -c '(with-input-from-string ",@" (lambda () (read)))'

I will investigate, but I don’t fully understand.

Regards,
Florian




Information forwarded to bug-guix <at> gnu.org:
bug#49910; Package guix. (Fri, 06 Aug 2021 12:17:02 GMT) Full text and rfc822 format available.

Message #8 received at 49910 <at> debbugs.gnu.org (full text, mbox):

From: Leo Prikler <leo.prikler <at> student.tugraz.at>
To: 49910 <at> debbugs.gnu.org
Subject: Fwd: Re: [website] script generating POT files broken with guile <at> 3.0.7
Date: Fri, 06 Aug 2021 14:16:16 +0200
[Message part 1 (text/plain, inline)]
Misremembered the bug ID, sorry
[Message part 2 (message/rfc822, inline)]
From: Leo Prikler <leo.prikler <at> student.tugraz.at>
To: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>, 
	49010 <at> debbugs.gnu.org
Subject: Re: [website] script generating POT files broken with guile <at> 3.0.7
Date: Fri, 06 Aug 2021 14:02:03 +0200
Hi Florian,

Am Freitag, den 06.08.2021, 12:53 +0200 schrieb pelzflorian (Florian
Pelz):
> Hello Guix!
> 
> In the guix-artwork.git repo, the pot file generation
> (scripts/sexp-xgettext.scm as described in the file i18n-howto) in
> the website is broken since guile <at> 3.0.7.  Old guile <at> 3.0.2 works.
> 
> The issue is at the end of the procedure in the call to (read) within
> token->string-symbol-or-keyw, specifically
> 
> guile -c '(with-input-from-string ",@" (lambda () (read)))'
> 
> I will investigate, but I don’t fully understand.
Having written a Scheme-specific xgettext implementation myself, I
think the issue here is that guile <at> 3.0.7 returns syntax objects from
(read), whereas previous guile does not.

The trick that I'm applying is to call syntax->datum on the return
value of (read).  In older guile, this does nothing, whereas in newer
guile it returns the symbol, keyword, list... whatever (read) would
have returned in the old implementation.

I hope this works out for you the way it did for me.

Cheers!

Information forwarded to bug-guix <at> gnu.org:
bug#49910; Package guix. (Sat, 07 Aug 2021 11:09:02 GMT) Full text and rfc822 format available.

Message #11 received at 49910 <at> debbugs.gnu.org (full text, mbox):

From: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>
To: Leo Prikler <leo.prikler <at> student.tugraz.at>
Cc: 49910 <at> debbugs.gnu.org
Subject: Re: bug#49910: Fwd: Re: [website] script generating POT files broken
 with guile <at> 3.0.7
Date: Sat, 7 Aug 2021 13:08:20 +0200
On Fri, Aug 06, 2021 at 02:16:16PM +0200, Leo Prikler wrote:
> > guile -c '(with-input-from-string ",@" (lambda () (read)))'
> The trick that I'm applying is to call syntax->datum on the return
> value of (read).

This must be a different error because guile errors out without return
value, but thank you for making me read the guile NEWS file again.  I
had forgotten there was a rewrite of (read).

I have pushed a workaround to guix-artwork as
f66b87373b33974751d2567f8c433ce44d07f10a and will take another look at
guile’s behavior now.

Regards,
Florian




Reply sent to "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>:
You have taken responsibility. (Wed, 18 Aug 2021 10:22:01 GMT) Full text and rfc822 format available.

Notification sent to "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>:
bug acknowledged by developer. (Wed, 18 Aug 2021 10:22:01 GMT) Full text and rfc822 format available.

Message #16 received at 49910-done <at> debbugs.gnu.org (full text, mbox):

From: "pelzflorian (Florian Pelz)" <pelzflorian <at> pelzflorian.de>
To: 49910-done <at> debbugs.gnu.org
Subject: Re: bug#49910: Fwd: Re: [website] script generating POT files broken
 with guile <at> 3.0.7
Date: Wed, 18 Aug 2021 12:21:17 +0200
I’m closing this issue since a workaround is in place.

The current behavior of the website’s sexp-xgettext script is wrong
(and was wrong before with guile <at> 3.0.2) when passing --keyword=quote
or --keyword=unquote-splicing but nobody does that anyway.

The script should be adapted with further development of (ice-9 read),
for example if comment parsing gets added[0], the PEG parser in
sexp-xgettext can be thrown away.

[0] https://lists.gnu.org/archive/html/guile-user/2021-08/msg00009.html

Regards,
Florian




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 15 Sep 2021 11:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 272 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.