GNU bug report logs - #22229
Error when running script from directory with non-ASCII characters

Previous Next

Package: guile;

Reported by: Vicente Vera <vicentemvp <at> gmail.com>

Date: Thu, 24 Dec 2015 01:47:02 UTC

Severity: normal

Done: Andy Wingo <wingo <at> pobox.com>

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 22229 in the body.
You can then email your comments to 22229 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-guile <at> gnu.org:
bug#22229; Package guile. (Thu, 24 Dec 2015 01:47:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to Vicente Vera <vicentemvp <at> gmail.com>:
New bug report received and forwarded. Copy sent to bug-guile <at> gnu.org. (Thu, 24 Dec 2015 01:47:02 GMT) Full text and rfc822 format available.

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

From: Vicente Vera <vicentemvp <at> gmail.com>
To: bug-guile <at> gnu.org
Subject: Error when running script from directory with non-ASCII characters
Date: Wed, 23 Dec 2015 22:46:21 -0300
Guile chokes when running a .scm script from a directory with
non-ASCII characters.

A simple test script:

-------------------
#!/usr/bin/guile -s
!#
;; coding: utf-8
(display "hey")
(newline)
-------------------

$ cd ~/código/
$ ./test.scm
;;; Stat of /home/me/c??digo/./test.scm failed:
;;; ERROR: In procedure stat: No such file or directory:
"/home/me/c??digo/./test.scm"
Backtrace:
In ice-9/boot-9.scm:
 157: 8 [catch #t #<catch-closure 9949e00> ...]
In unknown file:
   ?: 7 [apply-smob/1 #<catch-closure 9949e00>]
In ice-9/boot-9.scm:
  63: 6 [call-with-prompt prompt0 ...]
In ice-9/eval.scm:
 432: 5 [eval # #]
In ice-9/boot-9.scm:
2401: 4 [save-module-excursion #<procedure 9957cc0 at
ice-9/boot-9.scm:4045:3 ()>]
4052: 3 [#<procedure 9957cc0 at ice-9/boot-9.scm:4045:3 ()>]
1724: 2 [%start-stack load-stack ...]
1729: 1 [#<procedure 995e738 ()>]
In unknown file:
   ?: 0 [primitive-load "/home/me/c??digo/./test.scm"]

ERROR: In procedure primitive-load:
ERROR: In procedure open-file: No such file or directory:
"/home/me/c??digo/./test.scm"

When removing the UTF-8 character from the working directory Guile
runs as expected:

$ cd ~
$ mv -T código/ code/
$ cd code/
$ ./test.scm
hey

Locale: en_US.UTF-8

System: Linux 3.16.0-4-686-pae #1 SMP Debian 3.16.7-ckt20-1+deb8u1
(2015-12-14) i686 GNU/Linux

Guile version:
$ guile -v
guile (GNU Guile) 2.0.11
Packaged by Debian (2.0.11-deb+1-9)
...




Information forwarded to bug-guile <at> gnu.org:
bug#22229; Package guile. (Mon, 28 Mar 2016 03:58:01 GMT) Full text and rfc822 format available.

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

From: Alex Vong <alexvong1995 <at> gmail.com>
To: 22229 <at> debbugs.gnu.org
Subject: Re: Error when running script from directory with non-ASCII characters
Date: Mon, 28 Mar 2016 11:57:00 +0800
Hi,

I can reproduce the bug on Debian stable
using Guile from Debian and Guile from Guix (on top of Debian).

Debian version:
Linux debian 3.16.0-4-amd64 #1 SMP Debian 3.16.7-ckt20-1+deb8u4 (2016-02-29) x86_64 GNU/Linux

Debian's Guile version:
guile (GNU Guile) 2.0.11
Packaged by Debian (2.0.11-deb+1-9)
Copyright (C) 2014 Free Software Foundation, Inc.

License LGPLv3+: GNU LGPL 3 or later <http://gnu.org/licenses/lgpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Guix's Guile version:
guile (GNU Guile) 2.0.11
Copyright (C) 2014 Free Software Foundation, Inc.

License LGPLv3+: GNU LGPL 3 or later <http://gnu.org/licenses/lgpl.html>.
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Using Debian's Guile:
$ ./test.scm
;;; Stat of /home/alexvong1995/c??digo/./test.scm failed:
;;; ERROR: In procedure stat: No such file or directory: "/home/alexvong1995/c??digo/./test.scm"
Backtrace:
In ice-9/boot-9.scm:
 157: 8 [catch #t #<catch-closure bf6a20> ...]
In unknown file:
   ?: 7 [apply-smob/1 #<catch-closure bf6a20>]
In ice-9/boot-9.scm:
  63: 6 [call-with-prompt prompt0 ...]
In ice-9/eval.scm:
 432: 5 [eval # #]
In ice-9/boot-9.scm:
2401: 4 [save-module-excursion #<procedure c13980 at ice-9/boot-9.scm:4045:3 ()>]
4052: 3 [#<procedure c13980 at ice-9/boot-9.scm:4045:3 ()>]
1724: 2 [%start-stack load-stack #<procedure c1e080 at ice-9/boot-9.scm:4041:10 ()>]
1729: 1 [#<procedure c2af00 ()>]
In unknown file:
   ?: 0 [primitive-load "/home/alexvong1995/c??digo/./test.scm"]

ERROR: In procedure primitive-load:
ERROR: In procedure open-file: No such file or directory: "/home/alexvong1995/c??digo/./test.scm"

Using Guix's Guile:
$ ./test.scm 
;;; Stat of /home/alexvong1995/c??digo/./test.scm failed:
;;; ERROR: In procedure stat: No such file or directory: "/home/alexvong1995/c??digo/./test.scm"
Backtrace:
In ice-9/boot-9.scm:
 157: 8 [catch #t #<catch-closure 26c9780> ...]
In unknown file:
   ?: 7 [apply-smob/1 #<catch-closure 26c9780>]
In ice-9/boot-9.scm:
  63: 6 [call-with-prompt prompt0 ...]
In ice-9/eval.scm:
 432: 5 [eval # #]
In ice-9/boot-9.scm:
2401: 4 [save-module-excursion #<procedure 26e6980 at ice-9/boot-9.scm:4045:3 ()>]
4052: 3 [#<procedure 26e6980 at ice-9/boot-9.scm:4045:3 ()>]
1724: 2 [%start-stack load-stack ...]
1729: 1 [#<procedure 26fdf00 ()>]
In unknown file:
   ?: 0 [primitive-load "/home/alexvong1995/c??digo/./test.scm"]

ERROR: In procedure primitive-load:
ERROR: In procedure open-file: No such file or directory: "/home/alexvong1995/c??digo/./test.scm"




Information forwarded to bug-guile <at> gnu.org:
bug#22229; Package guile. (Sun, 07 Aug 2016 11:08:02 GMT) Full text and rfc822 format available.

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

From: Andy Wingo <wingo <at> pobox.com>
To: Vicente Vera <vicentemvp <at> gmail.com>
Cc: 22229 <at> debbugs.gnu.org
Subject: Re: bug#22229: Error when running script from directory with
 non-ASCII characters
Date: Sun, 07 Aug 2016 13:07:47 +0200
On Thu 24 Dec 2015 02:46, Vicente Vera <vicentemvp <at> gmail.com> writes:

> Guile chokes when running a .scm script from a directory with
> non-ASCII characters.
>
> A simple test script:
>
> -------------------
> #!/usr/bin/guile -s
> !#
> ;; coding: utf-8
> (display "hey")
> (newline)
> -------------------
>
> $ cd ~/código/
> $ ./test.scm
> ;;; Stat of /home/me/c??digo/./test.scm failed:
> ;;; ERROR: In procedure stat: No such file or directory:

Weird :)

It's fixed in Guile 2.2 because Guile 2.2 installs the locale
automatically; see GUILE_INSTALL_LOCALE here:

  https://www.gnu.org/software/guile/manual/html_node/Environment-Variables.html

I don't know what to do about Guile 2.0 though.  And of course it's
possible even with Guile 2.2 to be in a directory whose name is not
valid in the current encoding.

Though I would like to fix it nicely, I suspect that given the proximity
of 2.2.0, we'll just punt on 2.0 :(  A bit frustrating though.

Andy




Information forwarded to bug-guile <at> gnu.org:
bug#22229; Package guile. (Thu, 11 Aug 2016 17:54:01 GMT) Full text and rfc822 format available.

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

From: Vicente Vera <vicentemvp <at> gmail.com>
To: Andy Wingo <wingo <at> pobox.com>
Cc: 22229 <at> debbugs.gnu.org
Subject: Re: bug#22229: Error when running script from directory with
 non-ASCII characters
Date: Thu, 11 Aug 2016 14:53:25 -0300
Hello. Thanks for your reply.

Executing the script with GUILE_INSTALL_LOCALE=1 works as expected.

2016-08-07 7:07 GMT-04:00 Andy Wingo <wingo <at> pobox.com>:
> On Thu 24 Dec 2015 02:46, Vicente Vera <vicentemvp <at> gmail.com> writes:
>
>> Guile chokes when running a .scm script from a directory with
>> non-ASCII characters.
>>
>> A simple test script:
>>
>> -------------------
>> #!/usr/bin/guile -s
>> !#
>> ;; coding: utf-8
>> (display "hey")
>> (newline)
>> -------------------
>>
>> $ cd ~/código/
>> $ ./test.scm
>> ;;; Stat of /home/me/c??digo/./test.scm failed:
>> ;;; ERROR: In procedure stat: No such file or directory:
>
> Weird :)
>
> It's fixed in Guile 2.2 because Guile 2.2 installs the locale
> automatically; see GUILE_INSTALL_LOCALE here:
>
>   https://www.gnu.org/software/guile/manual/html_node/Environment-Variables.html
>
> I don't know what to do about Guile 2.0 though.  And of course it's
> possible even with Guile 2.2 to be in a directory whose name is not
> valid in the current encoding.
>
> Though I would like to fix it nicely, I suspect that given the proximity
> of 2.2.0, we'll just punt on 2.0 :(  A bit frustrating though.
>
> Andy




Reply sent to Andy Wingo <wingo <at> pobox.com>:
You have taken responsibility. (Tue, 28 Feb 2017 14:39:02 GMT) Full text and rfc822 format available.

Notification sent to Vicente Vera <vicentemvp <at> gmail.com>:
bug acknowledged by developer. (Tue, 28 Feb 2017 14:39:02 GMT) Full text and rfc822 format available.

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

From: Andy Wingo <wingo <at> pobox.com>
To: Vicente Vera <vicentemvp <at> gmail.com>
Cc: 22229-done <at> debbugs.gnu.org
Subject: Re: bug#22229: Error when running script from directory with
 non-ASCII characters
Date: Tue, 28 Feb 2017 15:38:06 +0100
On Thu 11 Aug 2016 19:53, Vicente Vera <vicentemvp <at> gmail.com> writes:

> Hello. Thanks for your reply.
>
> Executing the script with GUILE_INSTALL_LOCALE=1 works as expected.

In that case let's mark as closed.  Thanks again for the report and
sorry for the inconvenience.

Regards,

Andy




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

This bug report was last modified 8 years and 87 days ago.

Previous Next


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