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

undefined method `safe_load' for Psych:Module #156

Closed
trinistry opened this issue Oct 1, 2017 · 4 comments
Closed

undefined method `safe_load' for Psych:Module #156

trinistry opened this issue Oct 1, 2017 · 4 comments

Comments

@trinistry
Copy link

trinistry commented Oct 1, 2017

Hello,
this is what I am getting on "u3d run" on AWS linux.

`[root@ip-xxx JenkinsTest]# gem list

*** LOCAL GEMS ***

bigdecimal (1.2.0)
colored (1.2)
commander (4.4.3)
file-tail (1.2.0)
filesize (0.1.1)
highline (1.7.8)
inifile (3.0.0)
json (1.8.3)
plist (3.3.0)
psych (2.0.0)
rdoc (4.2.2)
security (0.1.3)
tins (1.15.0)
u3d (1.0.5)`

@lacostej
Copy link
Member

lacostej commented Oct 1, 2017

Hello @trinistry, interesting problem!

Questions: which ruby version are you using?

According to ruby/psych#119 , safe_load should have been in psych 2.0.0 but in https://github.com/ruby/psych/commits/d66158b8af4083cf2642a060751a6b9d7d8c0b27?after=d66158b8af4083cf2642a060751a6b9d7d8c0b27+34&path%5B%5D=lib&path%5B%5D=psych.rb I wonder if it was broken until 2.0.1.

As a consequence, could you try updating psych to 2.0.1? I am not really sure who pulls psych in, as I don't have a dependency to it on my system. I think it comes with old rubies. I don't think u3d is supported on ruby < 2.1 yet.

@lacostej
Copy link
Member

lacostej commented Oct 1, 2017

I made some tests on a system ruby on a Mac and I reproduce the issue.

Updating psych solves it, but there are other issues with using ruby < 2.1

I would recommend using ruby 2.1 or later. There are other issues with ruby 2.0 when coming from the system. E.g. openssl that comes with system.

@trinistry
Copy link
Author

You are correct, I had ruby version 2.0.0. After upgrading to 2.4.0 the psych error is gone, thank you!

@lacostej
Copy link
Member

lacostej commented Oct 1, 2017

@trinistry Great. Don't hesitate to send some feedback!

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

No branches or pull requests

2 participants