-
-
Notifications
You must be signed in to change notification settings - Fork 263
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
Bundle command does not work for versions after ruby/setup-ruby@v1.112.0 for windows #371
Comments
Interesting, maybe the (and it worked in 1.112.0 because of |
What's odd is it does work in this repo's tests: https://github.com/ruby/setup-ruby/runs/7705639587?check_suite_focus=true#step:17:1 Maybe the BTW you can also use |
I think you need to remove EDIT: I just checked my copy of 3.1.2, and it does have the file. Not.sure.why. @larskanis ? |
I'm trying to add a |
JFYI, I can't look into it right now, but at one point bin files were installed that would run from a bash script or a Windows command. They had a So there was no EDIT: Just checked, Windows Ruby 3.0.4 has the dual-purpose scripts, 3.1.2 has the normal scripts, where |
So the versions which fail are 3.0, 3.1, head, mswin. |
mswin has the file, buts it's the dual-purpose file. ruby-loco's mingw and ucrt builds have a lot of custom code in them. It's not broke, so I've never removed it. But, its mswin build is standard script, similar to what's used in ruby/ruby CI. So, I think the issue is with CRuby. But, I need to look at it, because making it work is a bit tricky if one is running the bundle command from a ruby that isn't the env Ruby. |
See GoogleCloudPlatform/functions-framework-ruby#142 for a fix. |
My job also fails due to missing
What is the actual fix? I don't cannot it. |
@msteinbeck I think the fix is to remove this line: https://github.com/msteinbeck/tinyspline/blob/b96a2d334c4be5282078d42a61d9105136f63cab/.github/workflows/ci.yml#L585 (i.e. don't use Also, you can remove the line with |
Removing |
Issue for RubyInstaller2: oneclick/rubyinstaller2#299 and for CRuby: https://bugs.ruby-lang.org/issues/18970 I guess for now we'll to workaround in setup-ruby by force-installing Bundler on Windows :/ |
Fixed this in mswin. To keep the install portable, bash binstubs start with a shebang line, which is the same as the ucrt & mingw builds. When running the 'Windows' binstubs (cmd or bat files), they will run with the Ruby exe file in the same folder. I haven't figured out a way to do so with the bash binstubs, so they use the ENV/PATH ruby. |
The |
I thought the exec flag was ignored in Windows. JFYI, I added a step to the mswin build CI to test the bash binstubs. Script is here, most recent CI log is here. I guess I could fix it in the build scripts... |
Yeah, but apparently there is some handling in Bash or so to decide if a file is executable (maybe it checks if there is a |
Correct. Fixed.
EDIT: I forgot to mention... When I tried to get the existing bash binstub working, it appeared to work fine in a cmd shell, but when using PowerShell, it opened a cmd window. So, given that many Windows developers probably use PowerShell, I decided to use a standard bash binstub. |
By |
I'll move to the Ruby issue 18970. I just ran this in my fork, and all the ruby-loco builds passed. Actions has been squirrelly recent, and I've seen intermittent failures. Not sure what the issue is, might be network related. Anyway, any thoughts on not installing bundler on the ruby-loco builds? I really don't like installing Bundler in master builds... |
OK, I'll remove that and only do it for 3.0+ releases, and |
Thanks. |
Using Windows bash shell (either Git or MSYS2), Some console output below,
|
I'm not sure what to understand from this output but it seems somehow the ruby-mswin BTW I noticed that What's needed to make |
The Windows file system does not natively support 'executable'. Using CLI or Ruby's Obviously some files do show 'executable' when using |
Found an interesting item: MSYS2, from which Git for Windows is built on, virtually adds the "execution bit" to file permissions for *.exe files and for files that starts with a shebang, for example #!/usr/bin/env bash, but they are never stored in the file system. So, the current bash files in mswin start with the following:
I changed that to:
Now, So, I haven't changed it yet, but I may change all the ruby-loco builds to the above... |
Failed workflow - https://github.com/GoogleCloudPlatform/functions-framework-ruby/runs/7795974033?check_suite_focus=true
The above workflow is with @v1 and it fails when we run "bundle install && gem install --no-document toys" with the error - bundle: command not found
The workflow runs fine for v1.112.0 : https://github.com/GoogleCloudPlatform/functions-framework-ruby/runs/7813891709?check_suite_focus=true
However fails for versions after that.
Here is the run for v1.113.0: https://github.com/GoogleCloudPlatform/functions-framework-ruby/runs/7813819674?check_suite_focus=true
The text was updated successfully, but these errors were encountered: