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

Ruby gems are not found after successful install #14

Open
darabi opened this issue Dec 9, 2022 · 2 comments
Open

Ruby gems are not found after successful install #14

darabi opened this issue Dec 9, 2022 · 2 comments

Comments

@darabi
Copy link

darabi commented Dec 9, 2022

I would like to use ruby gem nokogiri with MetaCall (installed with install.sh) and am using the repo metacall/express-faas-rpc-example as a starting point.

I added a corresponding Gemfile, called metacall bundler install which reports the gem as being present.

When I add the `require 'nokogiri' statement to mult.rb, I get

Loading... mult.rb
Error: Ruby module evaluation failed
#<LoadError: cannot load such file -- nokogiri>
(eval):1:in `require'
(eval):1:in `<main>'
Error: Invalid ruby module loading /wrk/metacall/express-faas-rpc-example/scripts/mult.rb
Error: No module could be loaded
Error: Handle (nil) passed to metacall_handle_export is not valid
NodeJS Loader Error: MetaCall could not load from file

@viferga mentioned in the Discord chat that this is related to some environment variables and to #5.

@viferga
Copy link
Member

viferga commented Feb 21, 2024

@darabi Even when adding the env vars:

It seems ruby is totally fucked. I could not make ruby find the gems installed by bundler, and other gems fail horribly like the ones I have added in the test.

If you are more experienced than me with Ruby, you can try to debug it: 5eb042f

It would be also interesting to report this to Guix team.

@shaggyyy2002
Copy link
Contributor

@darabi try updating the ruby to v3 or latest stable release. that should solve your problem. Have faced the problem too.
for more you could check this out: https://nokogiri.org/tutorials/installing_nokogiri.html

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