Forum: JRuby tempfile unlink

Announcement (2017-05-07): is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see and for other Rails- und Ruby-related community platforms.
701f3fd7de1c50b039c7591491ea97ab?d=identicon&s=25 Tristan Hill (Guest)
on 2014-04-01 11:07
(Received via mailing list)

I'm getting this warning from jruby:

warning: Tempfile#unlink or delete called on open file; ignoring

mechanisze does this:

  def make_tempfile name
    io = name
    io.binmode if io.respond_to? :binmode

I raised a bug with mechanize
( thinking it
might be ill advised usage.  Having looked at the bug for the warning
( it seems to only be a
precaution against certain file methods (e.g. stat) not working, so
should be fine if such methods aren't used.

Any recommendations?

Bec38d63650c8912b6ba9b557fb953b9?d=identicon&s=25 Roger Pack (rogerdpack)
on 2014-05-06 21:50
Seems it's actually an "almost expected" behavior in windows [according
you *should* write it this way and in POSIX land it will work, and in
windows, gracefully not work].

However, it is annoying that apparently this is "the right use" but
spits out an annoying warning message in windows...I wonder if something
could be done there...
This topic is locked and can not be replied to.