Skip to content

Something wrong with requires on 10.0 (broken dry-validation gem for example) #8777

@slbug

Description

@slbug
gem install dry-validation && jruby -e 'require "dry-validation"'

Environment Information

jruby 10.0.0.0 (3.4.2) 2025-04-13 6ed59bc847 Java HotSpot(TM) 64-Bit Server VM 24.0.1+9-30 on 24.0.1+9-30 +indy +jit [x86_64-darwin]

Expected Behavior

No NameError

Actual Behavior

NameError: uninitialized constant Dry::Core::Container::Mixin
      const_missing at org/jruby/RubyModule.java:4857
  <class:Container> at ~/.rvm/gems/jruby-10.0.0.0/gems/dry-core-1.1.0/lib/dry/core/container.rb:24
      <module:Core> at ~/.rvm/gems/jruby-10.0.0.0/gems/dry-core-1.1.0/lib/dry/core/container.rb:23
       <module:Dry> at ~/.rvm/gems/jruby-10.0.0.0/gems/dry-core-1.1.0/lib/dry/core/container.rb:4
             <main> at ~/.rvm/gems/jruby-10.0.0.0/gems/dry-core-1.1.0/lib/dry/core/container.rb:3
            require at org/jruby/RubyKernel.java:1183

If I manually require this mixin before dry-validation it fails with error reported in #8776

❯ jruby -e 'require "dry/core/container/mixin"; require "dry-validation"'
SyntaxError: ~/.rvm/gems/jruby-10.0.0.0/gems/dry-types-1.8.2/lib/dry/types/constrained.rb:109: setter method cannot be defined in an endless method definition
           require at org/jruby/RubyKernel.java:1183

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions