JRuby (please use github issues at http://bugs.jruby.org)
  1. JRuby (please use github issues at http://bugs.jruby.org)
  2. JRUBY-6649

Opening a file with a hash as options will raise an `ArgumentError: invalid access mode 4610` exception

    Details

    • Type: Bug Bug
    • Status: Resolved Resolved
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: JRuby 1.7.0.pre1
    • Fix Version/s: JRuby 1.7.0.pre1
    • Component/s: None
    • Labels:
      None
    • Testcase included:
      yes
    • Number of attachments :
      1

      Description

      Possibly related to JRUBY-6648.

      If you open a file with certain hash flags for `mode` and `encoding`, an `ArgumentError: invalid access mode 4610` will be raised.

      I've attached a test that passes on 1.9.3 and raises an exception on JRuby master.

      1. test.rb
        0.3 kB
        Aaron Patterson

        Activity

        Hide
        Thomas E Enebo added a comment -

        Bad assumption in options processing ([master 8f7867a]). Aaron, can I assume this test will be added to MRI's test suite?

        Show
        Thomas E Enebo added a comment - Bad assumption in options processing ( [master 8f7867a] ). Aaron, can I assume this test will be added to MRI's test suite?
        Hide
        Aaron Patterson added a comment -

        Would you like it to be? This bug was making some of my psych tests fail, but I wasn't specifically testing this behavior.

        Show
        Aaron Patterson added a comment - Would you like it to be? This bug was making some of my psych tests fail, but I wasn't specifically testing this behavior.
        Hide
        Thomas E Enebo added a comment -

        Yeah it would be nice if there were a test somewhere for the combinations of new open arguments. MRI test suite is something you have easy access to

        Show
        Thomas E Enebo added a comment - Yeah it would be nice if there were a test somewhere for the combinations of new open arguments. MRI test suite is something you have easy access to
        Hide
        Aaron Patterson added a comment -

        You got it! I'll make sure there's a tests specifically for this stuff! <3

        Show
        Aaron Patterson added a comment - You got it! I'll make sure there's a tests specifically for this stuff! <3

          People

          • Assignee:
            Thomas E Enebo
            Reporter:
            Aaron Patterson
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: