Calling non-MSYS programs passes invalid env
Nobody has claimed this yet.
- Dominant language
- C
- Stars
- 240
- Forks
- 60
- Avg merge
- 2d 3h
- Merged PRs (30d)
- 1
Description
I originally opened this issue in swiftlang/swift#84428 but compnerd made a very valid statement about Windows being case insensitive with the environment.
MSYS2 shells have a case sensitive environment, and they pass this to programs being called as well. This is usually not a problem by either sheer coincidence or the key/value nature of handling the env. But some programs that don't live inside MSYS2 that do happen to get called end up crashing on the key already existing (after normalization).
The existing interop story for MSYS2 already does some mangling of the environments and paths, so perhaps cleaning up the environment for programs that don't live under MSYS2 could be part of this? For reliable behavior, always passing the last defined value for an env var would seem like the best option to ensure behavior like overriding the value on the command line or in scripts.
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source file, test, or entry point is identified in the issue. Start by locating the MSYS2 environment and path interop handling for programs outside MSYS2, then define and test the expected behavior when case-insensitive environment names collide, including which value is retained.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- c
- Domain
- operating-systems
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100