Ruben Laguna's blog

Mar 19, 2007 - 1 minute read - flush netbeans puts ruby stdout

Netbeans 6.0 Ruby output not working properly ($stdout is not flushed on program termination)

After struggling with Netbeans 6.0 Ruby a little bit I finally found why my puts statement are not working properly. It’s due to the following reported bug.(Vote for this bug!!) Also noted in the RubyTodo page from Netbeans wiki.

This problem appears when using native ruby with netbeans instead of jruby.

My workaround is using log4r instead for print statements.

UPDATE: It has been fixed in the latest version of the ruby module. I had to download the prebuilt ruby cluster from http://deadlock.nbextras.org/hudson/job/ruby/ and install it using the following instructions because the ruby module version found in the update center was not fresh enough but today I checked again and version 0.39 is available from the Update Center as well.