Skip to content

Process 1.6.13 changed observable behaviour #227

Description

@angerman

Reproducer is https://github.com/angerman/repro-process-behaviour-change-1.6.13

Will produce the following output:

$ make all CABAL=$(which cabal) GHC=$(which ghc)
Building against process < 1.6.13 ...
Running against process < 1.6.13; with an empty PATH, this should result in a git not found message
<no git executable found>
Building against process >= 1.6.13 ...
Running against process >= 1.6.13; this now throws an exception instead.
process-crash: git: readCreateProcessWithExitCode: posix_spawnp: failed (Undefined error: 0)
make: *** [Makefile:9: all] Error 1

We are now throwing an exception where we didn't before.

Activity

  1. bgamari commented on Jan 11, 2022

    @bgamari
    Contributor

    Thanks @angerman, I'll investigate!

  2. self-assigned this
    on Jan 11, 2022
  3. bgamari commented on Jan 11, 2022

    @bgamari
    Contributor

    Which operating system is this reproducible on?

  4. bgamari commented on Jan 11, 2022

    @bgamari
    Contributor

    I cannot reproduce this on Linux.

    Speaking to @angerman, it seems that they only see this on Darwin.

  5. bgamari commented on Jan 11, 2022

    @bgamari
    Contributor

    @angerman says that posix_spawnp returns 2. However, the log output clearly suggests that errno==0. The problem appears to be that Darwin's posix_spawnp implementation does not set errno whereas glibc's appears to. This is the source of the discrepancy.

  6. added a commit that references this issue on Jan 11, 2022
    3d9f244
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

No labels
No labels

Type

No type

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions