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

dry-types-0.15.0/lib/dry/types/nominal.rb:32:in `initialize': wrong number of arguments (given 2, expected 1) (ArgumentError) #18

Open
diegopolido opened this issue Jun 3, 2024 · 1 comment

Comments

@diegopolido
Copy link

Após adicionar a gem no projeto e tentar adicionar uma migration, apareceu esse erro. Alguma ideia do que pode ser? Obrigado!

stacktrace:

/home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/nominal.rb:32:in `initialize': wrong number of arguments (given 2, expected 1) (ArgumentError)
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/any.rb:9:in `initialize'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/any.rb:34:in `new'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/any.rb:34:in `<module:Types>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/any.rb:2:in `<module:Dry>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/any.rb:1:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/zeitwerk-2.6.15/lib/zeitwerk/kernel.rb:34:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types/core.rb:1:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/zeitwerk-2.6.15/lib/zeitwerk/kernel.rb:34:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry/types.rb:173:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/zeitwerk-2.6.15/lib/zeitwerk/kernel.rb:34:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/dry-types-0.15.0/lib/dry-types.rb:1:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/zeitwerk-2.6.15/lib/zeitwerk/kernel.rb:34:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/asaas-ruby-0.2.27/lib/asaas-ruby.rb:6:in `<main>'
	from <internal:/home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
	from <internal:/home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/rubygems/core_ext/kernel_require.rb>:37:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/zeitwerk-2.6.15/lib/zeitwerk/kernel.rb:34:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler/runtime.rb:60:in `block (2 levels) in require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler/runtime.rb:55:in `each'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler/runtime.rb:55:in `block in require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler/runtime.rb:44:in `each'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler/runtime.rb:44:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundler.rb:187:in `require'
	from /home/diegopolido/Projects/my_app/config/application.rb:7:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command/actions.rb:15:in `require_application!'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command/actions.rb:19:in `boot_application!'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/commands/generate/generate_command.rb:21:in `perform'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/thor-1.3.1/lib/thor/command.rb:28:in `run'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/thor-1.3.1/lib/thor/invocation.rb:127:in `invoke_command'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command/base.rb:178:in `invoke_command'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/thor-1.3.1/lib/thor.rb:527:in `dispatch'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command/base.rb:73:in `perform'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command.rb:71:in `block in invoke'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command.rb:149:in `with_argv'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/command.rb:69:in `invoke'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/railties-7.1.3.3/lib/rails/commands.rb:18:in `<main>'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/3.3.0/bundled_gems.rb:74:in `block (2 levels) in replace_require'
	from /home/diegopolido/.asdf/installs/ruby/3.3.0/lib/ruby/gems/3.3.0/gems/bootsnap-1.18.3/lib/bootsnap/load_path_cache/core_ext/kernel_require.rb:30:in `require'
	from bin/rails:4:in `<main>'
@diegopolido
Copy link
Author

diegopolido commented Jun 3, 2024

Após olhar o repositório do projeto DryTypes, vi que existe uma issue com o Ruby 3+ dry-rb/dry-types#459

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

1 participant