-
Notifications
You must be signed in to change notification settings - Fork 428
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
conda_build/windows.py: avoid trailing semicolon in %MSYS2_ARG_CONV_EXCL% #1651
Conversation
…XCL% The previous method of setting the %MSYS2_ARG_CONV_EXCL% environment variable tried to preserve any preexisting value of the variable. Not only does this make the build process depend on the initial environment more, it generally leads to a trailing semicolon in the variable value. This seems to cause MSYS2 to parse the variable as having an empty value that prevents *all* argument conversions, as investigated in the conda-forge `cairo` package: conda-forge/cairo-feedstock#18. I do not know what fallout this change will have for existing build scripts, but the current behavior cannot be what was intended.
This is strange, I put fixes into MSYS2 specifically for what you describe. Unfortunately I don't have much time to look into it, so I'd say merge it anyway. |
Perhaps that's related to another thing I noticed in my testing? The |
Git for Windows is based on MSYS2 and is (obviously) installed on CI machines. So if you are using Other than that, if you haven't installed the |
cygpath.exe is not provided in miniconda, I think. @pkgw can you please verify that? I think it's just part of the standard AppVeyor installation, which is where you're picking it up from. |
It is part of |
Yes, right, to be more precise: the But here's what I'm talking about. On my Windows VM, I set up a demo "package" with a dependency on
The first invocation uses the (I guess it bears emphasis that all of this may or may not have anything to do with this pull request, but if there's supposed to be a patch that fixes this problem in MSYS2, I do wonder if there's some kind of mixed package versioning going on.) |
Your VM's Miniconda install probably does not have the |
Ah, yes, that makes things consistent. Should Well, that clears up that particular thing, but still leaves the possible issue with trailing semicolons. If the AppVeyor build of conda-forge Cairo ever runs (yesterday it sat on the queue for like 14 hours) I'll be able to check that it's still a problem, in that particular build setup, at least ... |
No IMHO it shouldn't, |
@pkgw can you confirm whether Cairo ran successfully? Is this PR still necessary? |
Yes, with that Cairo PR, the equivalent of this change was the difference between success and failure. So, to the best of my knowledge, this PR is necessary, unless something about conda-build has changed in the past few days. In principle it'd be interesting to understand if/why the fix alluded to by @mingwandroid didn't work or isn't active on the conda-forge builders, though. |
All right, I'm going to merge this. I kind of doubt we've seen the last of this issue, though. If we revisit it, I think we might do better to have Python check for that variable in os.environ, and if set, do the concatenation itself and place the value directly as a string with no env var component. |
Hi there, thank you for your contribution! This pull request has been automatically locked because it has not had recent activity after being closed. Please open a new issue or pull request if needed. Thanks! |
The previous method of setting the
%MSYS2_ARG_CONV_EXCL%
environment variable tried to preserve any preexisting value of the variable. Not only does this make the build process depend on the initial environment more, it generally leads to a trailing semicolon in the variable value. This seems to cause MSYS2 to parse the variable as having an empty value that prevents all argument conversions, as investigated in the conda-forgecairo
package: see here.I do not know what fallout this change will have for existing build scripts, but the current behavior cannot be what was intended.