Skip to content
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

fatal error - add_item #282

Open
jsh562 opened this issue May 6, 2022 · 8 comments
Open

fatal error - add_item #282

jsh562 opened this issue May 6, 2022 · 8 comments

Comments

@jsh562
Copy link

jsh562 commented May 6, 2022

What problems are you experiencing?

Installing puma 5.6.4 with native extensions 0 [main] locale (9392) D:\Ruby26-x64\msys64\usr\bin\locale.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1 Stack trace: Frame Function Args 000FFFFCD30 001800627DE (0018029394A, 0018026EE41, 00800000000, 000FFFF8B30) 000FFFFCD30 0018004846A (00000000000, 000FFFFCD30, 00180020010, 000FFFFABF0) 000FFFFCD30 001800484A2 (000FFFF9BC0, 00000000001, 00800000000, 00000000001) 000FFFFCD30 001800E7167 (00000000000, 00040000024, 00000000000, 00000000000) 000FFFFCD30 0018012C705 (001800D63F4, 00000000000, 00000000000, 00000000000) 000FFFFCD30 00180048AB8 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 00180047716 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 001800477C4 (00000000000, 00000000000, 00000000000, 00000000000) End of stack trace 0 [main] make (9020) D:\Ruby26-x64\msys64\usr\bin\make.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1 0 [main] make (4616) D:\Ruby26-x64\msys64\usr\bin\make.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1 0 [main] make (10056) D:\Ruby26-x64\msys64\usr\bin\make.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1

occurs on about 20% of gems I try to install (not just puma as shown).
tried on either 2.6 and 2.7 with dev kit installed.

Steps to reproduce

install ruby 2.6 or 2.7 with msys2
install gems

What's the output from ridk version?

0 [main] locale (8312) D:\Ruby26-x64\msys64\usr\bin\locale.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1 Stack trace: Frame Function Args 000FFFFCD30 001800627DE (0018029394A, 0018026EE41, 00800000000, 000FFFF8B30) 000FFFFCD30 0018004846A (00000000000, 000FFFFCD30, 00180020010, 000FFFFABF0) 000FFFFCD30 001800484A2 (000FFFF9BC0, 00000000001, 00800000000, 00000000001) 000FFFFCD30 001800E7167 (00000000000, 00040000024, 00000000000, 00000000000) 000FFFFCD30 0018012C705 (001800D63F4, 00000000000, 00000000000, 00000000000) 000FFFFCD30 00180048AB8 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 00180047716 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 001800477C4 (00000000000, 00000000000, 00000000000, 00000000000) End of stack trace 0 [main] sh (7272) D:\Ruby26-x64\msys64\usr\bin\sh.exe: *** fatal error - add_item ("\??\D:\Ruby26-x64\msys64", "/", ...) failed, errno 1 Stack trace: Frame Function Args 000FFFFCD30 001800627DE (0018029394A, 0018026EE41, 00800000000, 000FFFF8B30) 000FFFFCD30 0018004846A (00000000000, 000FFFFCD30, 00180020010, 000FFFFABF0) 000FFFFCD30 001800484A2 (000FFFF9BC0, 00000000001, 00800000000, 00000000001) 000FFFFCD30 001800E7167 (00000000000, 00040000024, 00000000000, 00000000000) 000FFFFCD30 0018012C705 (001800D63F4, 00000000000, 00000000000, 00000000000) 000FFFFCD30 00180048AB8 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 00180047716 (00000000000, 00000000000, 00000000000, 00000000000) 000FFFFFFF0 001800477C4 (00000000000, 00000000000, 00000000000, 00000000000) End of stack trace D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:139:insanitize_hash_encoding': undefined method map' for nil:NilClass (NoMethodError) from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:139:in block in sanitize_hash_encoding'
from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:139:in each' from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:139:in map'
from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:139:in sanitize_hash_encoding' from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:182:in print_version'
from D:/Ruby26-x64/lib/ruby/site_ruby/2.6.0/ruby_installer/runtime/ridk.rb:24:in run!' from D:/Ruby26-x64/bin/ridk.cmd:39:in

'`

@mohits
Copy link
Collaborator

mohits commented May 7, 2022

Hmm.. Ruby26-x64 used to be my main stay version and I did not face anything like this at all.

[1] Could you share your PATH?

[2] The one difference I am seeing is that I have Ruby on my C drive rather than D drive as you seem to have... but I don't feel that it should make a difference.

[3] I'm assuming you have tried to reinstall Ruby?

[4] Which package did you install?

Thanks!

@jsh562
Copy link
Author

jsh562 commented May 9, 2022

  1. bin of ruby. e.g. D:\Ruby26-x64\bin

  2. yes

  3. the latest stable of each.

possibly related
https://stackoverflow.com/questions/66276259/gpg-exe-part-of-git-bash-crashes-with-fatal-error-add-item-windows
bazelbuild/continuous-integration#649

@jsh562
Copy link
Author

jsh562 commented May 24, 2022

Did some more testing.
2.6.7 does not give me these issues while 2.6.10 does.
I might test 2.7.[some previous version] as well

@jsh562
Copy link
Author

jsh562 commented May 31, 2022

2.6.8+
2.7.4+
3.0.1+
any ruby installer with the new icon gives these error

any older maintenance version work fine.

@mohits
Copy link
Collaborator

mohits commented Oct 12, 2024

Hi @jsh562 - it's 2+ years since the last message. Do you think we can close this?

@joshleblanc
Copy link

joshleblanc commented Jan 27, 2025

I'm seeing this in ruby 3.4.1 (2024-12-25 revision 48d4efcb85) +PRISM [x64-mingw-ucrt]

Image

Note that I've run this installer and the associated application installers dozens of times over the past month. This is the first time I've seen it on this version. I believe I was using a different patch on all those installs though.

This is the ridk version on the breaking install:


ruby:
path: C:/Ruby34-x64
version: 3.4.1
platform: x64-mingw-ucrt
ruby_installer:
package_version: 3.4.1-2
git_commit: ea9c116
msys2:
path: C:\Ruby34-x64\msys64
cc: gcc (Rev2, Built by MSYS2 project) 14.2.0
sh: GNU bash, version 5.2.37(1)-release (x86_64-pc-msys)
os: Microsoft Windows [Version 10.0.17763.6775]

This is the ridk version on the install I've never had a problem with:


ruby:
path: C:/Ruby34-x64
version: 3.4.1
platform: x64-mingw-ucrt
ruby_installer:
package_version: 3.4.1-1
git_commit: 4102aec
msys2:
path: C:\Ruby34-x64\msys64
cc: gcc (Rev2, Built by MSYS2 project) 14.2.0
sh: GNU bash, version 5.2.37(1)-release (x86_64-pc-msys)
os: Microsoft Windows [Version 10.0.19045.5371]

@jsh562
Copy link
Author

jsh562 commented Jan 30, 2025

wow, lol
maybe that was the problem all along, something with Windows

I tried so many different variations of versions and installations of everything I could think of except Windows.
I haven't tried recently but I could give it another try and see if the numerous Windows updates maybe fixed it?

@mohits
Copy link
Collaborator

mohits commented Jan 31, 2025

@joshleblanc - I seem to have exactly the same version as what you have got as "working". Two differences as you noticed between the working and non-working:

  • Windows version
  • ruby_installer package version

Is there something you'd like me to try?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants