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

Kernel.system does not utilize tailing arguments in 1.9 mode #2389

Closed
rjnienaber opened this issue Dec 30, 2014 · 1 comment
Closed

Kernel.system does not utilize tailing arguments in 1.9 mode #2389

rjnienaber opened this issue Dec 30, 2014 · 1 comment

Comments

@rjnienaber
Copy link

@rjnienaber rjnienaber commented Dec 30, 2014

From: http://jira.codehaus.org/browse/JRUBY-5707. Decent error message is displayed in JRuby 1.7.18 but ConcurrencyError is raised in JRuby 9000.

I attempted to call Kernel.system with tailing arguments in 1.9 mode, but Kernel.system only returned nil.

Steps to reproduce:
jruby --1.9 -S irb

system('ls', '-la', :out => ['log.txt','w'])

Expected result:
The log.txt file would be created.

Actual result:
nil is returned and log.txt is not created.

Documentation for tailing arguments: http://rubydoc.info/stdlib/core/1.9.2/frames

@kares
Copy link
Member

@kares kares commented Mar 1, 2018

has been resolved in 9K :

kares@sputnik:~/workspace/oss/jruby$ irb
jruby-9.1.15.0 :001 > system('ls', '-la', :out => ['log.txt','w'])
 => true 
jruby-9.1.15.0 :002 > puts `cat log.txt`
total 16188
drwxr-xr-x 27 kares kares  401408 Mar  1 15:16 .
drwxr-xr-x 89 kares kares    4096 Feb 24 10:17 ..
...

@kares kares closed this Mar 1, 2018
@kares kares added this to the Invalid or Duplicate milestone Mar 1, 2018
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

2 participants