active-hash / active_hash

A readonly ActiveRecord-esque base class that lets you use a hash, a Yaml file or a custom file as the datasource
MIT License
1.2k stars 179 forks source link

Release master for Ruby 3 compatibility #225

Closed nsommer closed 1 year ago

nsommer commented 3 years ago

Would you consider bumping the version and doing a release of master? ActiveHash currently does not run with Ruby 3, but it was already fixed on master (https://github.com/zilkey/active_hash/commit/f6448312c748f7e0f2846ed0d377074c974d3f7d).

nsommer commented 3 years ago

@kbrock @syguer any chance you would release soonish? 🙂

kbrock commented 3 years ago

Hi @syguer -- are you the one to push these changes live? Anything other people need to do to help with this effort?

aknicol commented 2 years ago

Have these issues for Ruby 3 been resolved? I'm still receiving Undefined method 'arity' on my model definitions.

aknicol commented 2 years ago

As I mentioned I'm still having issues, my code follows the example in the docs almost exactly, I have:

class Person < ActiveRecord::Base

  extend ActiveHash::Associations::ActiveRecordExtensions
  belongs_to_active_hash :country

on the next line,

belongs_to :surname, optional: true

I get the error undefined method `arity' for {:optional=>true}:Hash

cath-oneill commented 2 years ago

Finally upgrading to Ruby 3, and running into the same issues. It does appeared to be fixed for my use-case both in master (f644831) as @nsommer pointed out, and @gazayas' offered another possible fix in his PR. Anything that can be done to help get the work that's already been done released?

Sixeight commented 2 years ago

@zilkey Could you release a new version? Current version has some problem with Ruby 3.x. Or, How about an idea create new organization for this library to maintain the library by community. Thanks for the great library!

Sixeight commented 2 years ago

https://github.com/active-hash had been created. but the new version has not been released. does anyone has publishable permission?

aknicol commented 2 years ago

Has there been any progress on this?

yujideveloper commented 2 years ago

v3.1.1 has been released that supports Ruby 3.x. https://rubygems.org/gems/active_hash/versions/3.1.1

neocoin commented 1 year ago

@yujideveloper

Please release version v3.1.2.

I've made some monkey patches to make active_hash work in Ruby 3.2 and Rails 7.

For example, Ruby 3.2 must need these commits.

00f98114f9b3c22010a47f3f7b35b7aed1a33b5d bb111597fc2214f02670fb5d2d35f374a5f98466

yujideveloper commented 1 year ago

@neocoin Sorry, I don't have commit and release permissions.

@adampal @kbrock Could you release a new version?

neocoin commented 1 year ago

@adampal @kbrock plz check this library update.

kbrock commented 1 year ago

I just checked, I'm not an owner in gems. That is all @adampal or @flavorjones (the ones that I think are active). Also, could we merge #268 first? it has generated so many PRs and issues. Just in final review status.

Hmm, this CHANGELOG is going to be a doozy, I'll see if I can spare some cycles and get a PR in for that

flavorjones commented 1 year ago

@kbrock I'll make you an owner in rubygems -- can you confirm your username or email address for me?

flavorjones commented 1 year ago

@kbrock You've been invited as an owner on rubygems.org! :tada:

franzliedke commented 1 year ago

v3.2.0 is out. Thanks, @kbrock! 🎉

(So this can probably be closed now.)