GNU bug report logs - #64216
Proc open-input-pipe returns #eof when reading on macOS, works as expected on Linux

Previous Next

Package: guile;

Reported by: Jose Ortiz <kotshie <at> gmail.com>

Date: Thu, 22 Jun 2023 05:48:02 UTC

Severity: normal

Full log


View this message in rfc822 format

From: Jose Ortiz <kotshie <at> gmail.com>
To: 64216 <at> debbugs.gnu.org
Subject: bug#64216: Proc open-input-pipe returns #eof when reading on macOS, works as expected on Linux
Date: Wed, 21 Jun 2023 17:31:18 -0700
[Message part 1 (text/plain, inline)]
When reading from open-input-pipe, it returns #eof on macOS devices, while it works properly in Linux.

```
(use-modules (ice-9 popen)
             (ice-9 rdelim))
(let* ((port (open-input-pipe "date --utc"))
       (str  (read-line port)))
  (close-pipe port)
  str)
```
macOS> #<eof>
linux> "Thu Jun 22 12:30:26 AM UTC 2023"


Building latest and running popen.test also fails with:

m1 :: Projects/guile/test-suite ? guile -L . -e main -s guile-test tests/popen.test
Running tests/popen.test
                                                                                                                                                                  
FAIL: tests/popen.test: open-input-pipe: echo hello
FAIL: tests/popen.test: open-input-pipe: open-input-pipe process gets (current-input-port) as stdin
ERROR: tests/popen.test: open-output-pipe: no duplicate - arguments: ((wrong-type-arg "string-append" "Wro
ng type (expecting ~A): ~S" ("string" #f) (#f)))



- Jose
[Message part 2 (text/html, inline)]

This bug report was last modified 2 years and 10 days ago.

Previous Next


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