Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Please release Rails 4 compatible Mongoid gem to Rubygems.org #3128

Closed
nengxu opened this Issue · 34 comments

16 participants

nengxu Arthur Nogueira Neves Durran Jordan Mathieu Ripert Sven G. Brönstrup Christian Fazzini Nahuel Cuesta Luengo Zolzaya Erdenebaatar Steve Miles Smith John Axel Eriksson Sebastian Gassner Lucas Mazza Peter Fern James Smith Ben Crouse
nengxu

Rails 4 has been officially released today. Right now Mongoid 3.1.4 will cause conflict with Rails 4:

Bundler could not find compatible versions for gem "activemodel":
  In Gemfile:
    mongoid (~> 3.1.4) ruby depends on
      activemodel (~> 3.2) ruby

    rails (~> 4) ruby depends on
      activemodel (4.0.0)

The alternative approach of using github: "mongoid/mongoid" won't work in certain deployment environments, due to an old Bundler bug as described here:

bundler/bundler#2492

We need a compatible Mongoid gem at Rubygems.org to be able to upgrade to Rails 4. Please release one to Rubygems ASAP. Thanks.

Arthur Nogueira Neves
Owner

Mongoid 3.x wont work with rails 4. we did some crucial changes on master in order to be compatible with activemodel 4.0 . So this is not just easy as releasing a new version to rubygems.
That said, master is also not finalized yet, so we cannot release that as version 4.0 yet. I would say the solution for now is to use master from github, or if you cannot do this due the bundler issue, you still can clone the repo e reference it using the path: '~/foo/mongoid' option on Gemfile.

Arthur Nogueira Neves arthurnn closed this
nengxu

Any progress on Rails 4 compatible gem release? Using path: '~/foo/mongoid' is not an allowable option for deploying to servers. You know, in many companies, OPS guys are usually not the same DEV guys.

Durran Jordan
Owner

Mongoid 4 will not be released until the 2.0 version of the 10gen Ruby driver is released. This is currently set for August.

Mathieu Ripert

Do you have any updates on the release ? Or an estimate of the release date ?
Thanks

Sven G. Brönstrup

Accourding to https://jira.mongodb.org/browse/RUBY, 10gen's 2.0 driver will not be release until the end of the year. So perhaps you should release the mongoid 4.0 gem before.

Sven G. Brönstrup

At least a -pre, -beta, or -rc gem on rubygems would be handy.

Nahuel Cuesta Luengo

+1 on the pre-release.

Zolzaya Erdenebaatar

+1 on the pre-release

Arthur Nogueira Neves
Owner

We cannot release a pre-release as there are still some missing features that must be done before we close mongoid4. I am hoping to finish most of those features in the next week, than we can probably release a pre-release/beta version.

thanks

nengxu

Waiting for it. Thanks!

Steve

Also looking forward to a prerelease version on rubygems. Let me know if you'd like me to help with some of the issues that need to be close prior to release.

Miles Smith

Rails 4 was released several months ago. As the defacto standard for MongoDB in Rails, it seems weird that at the very least the documentation on mongoid.org hasn't been updated to reflect how to use Mongoid with the current stable version of Rails.

Is there anything that this is waiting on besides 10Gen's driver? I'd love to help in any way I can.

Arthur Nogueira Neves
Owner

@wedtm one of the biggest features that mongoid4 is waiting for is the new eager load. You can help out code reviewing it #3279 . Also we need to discuss some features like alias fields on json generation(#2849) .Besides that we need to decide which more features we gonna add to it. It is hard to just rush and release a new major version, and add new features afterwards.

Miles Smith

@arthurnn Thanks, looking now.

nengxu

@arthurnn Thanks for the update.
@wedtm Thanks for offering help.

I'm quite occupied by my projects. Cannot participate here. Good luck to you!

John Axel Eriksson

@durran @arthurnn So with the 10gen driver having it's release date set to 31 Dec 2013, am I correct in assuming Mongoid 4 won't be released until next year?

Sebastian Gassner

Hi, I am developing a gem for Rails 4 that depends on mongoid.

In gemspec, github dependencies are not allowed, only officially released gems, includeing pre-releases. Or, in other words, gems that have a version number.

As I understand, without at least a alpha/pre/beta/rc release of mongoid that depends on activemodel 4, no one will be able to develop any gems for Rails 4 and mongoid - until the end of Dec 2013. Are you serious?!

Could you please create a pre-release, e.g. mongoid-4.0.0.pre? Or could you tell me how to resolve this issue otherwise?

Thanks!

Lucas Mazza

@sepastian you can develop it but you can't release/install it. Use your Gemfile to point the mongoid gem to a local clone or the git repo. Something like this might work for you:

# gem.gemspec
s.add_dependency 'mongoid', '~> 4.0.0'
# Gemfile
gem 'mongoid', github: 'mongoid/mongoid'
Sebastian Gassner

Thanks for the quick reply.

Unfortunately, this does not help, because not being able to install the gem I am developing (until the end of the year) is not an option.

Why can't you release 4.0.0.alpha? What would be the problem with that? Rails 4 has been released several months ago, people are using the master branch of mongoid anyways. Plus people using an alpha version should know what they are doing.

Miles Smith

@sepastian One work around would be to manually download this repo, compile the gem yourself, and then either push it to rubygems as a different name, or use your own gem server. Fairly ugly hacks, I know, but at least you'd get to the end result you're looking for.

Sebastian Gassner

Thanks @wedtm, thats exactly what I did.

Peter Fern
pdf commented

@sepastian - personally I would have preferred if you made it obvious from the gem name that this is a personal build, so that people don't mistakenly assume it's in any way official or supported. In fact, I'd advocate deleting that gem and instead uploading it as sepastion-mongoid or something, and also most definitely updating the gem description to make it clear what this gem is.

Sebastian Gassner

@pdf, sure, will do that. This was just a quick hack, I needed to get things working for now, knowing that I would switch to the official gems as soon as they will become available.

James Smith

Mongoid 4 will not be released until the 2.0 version of the 10gen Ruby driver is released. This is currently set for August.

@durran I assume you mean until 10gen's 2.0 bson gem is released?

James Smith

Looks like the bson 2 gem has been released: http://rubygems.org/gems/bson

Steve

@durran @arthurnn @nengxu or anyone really -- has any progress been made on this? I still don't understand why you wouldn't want to release an "alpha" version on rubygems while we wait for the 10gen driver (which appears to have updated the "Due Date" to March of this year). 4.0.alpha seems like it would be appropriate and would help developers move forward.

Durran Jordan
Owner

@sdhull This is because the API is still changing in Mongoid, and there will probably be another release in the alpha phase while this happens, probably soon. But I won't release a beta until there are no more backwards incompatible changes going in.

Steve

@durran thanks for the reply. It's nice to know that this is intentional and not forgotten/neglected. Guess it's holding pattern till then. Any guesses about when the Mongoid API will be settled?

Also -- to be clear, we're not waiting on the linked 10gen driver ("Due" in March)? We're waiting on API to be settled for the Mongoid 4.x? Or perhaps the API changes in Mongoid are necessitated by the changes in the 10gen driver?

Durran Jordan
Owner

@sdhull No we are not waiting on the 10gen driver anymore. We were initially, but then that got delayed due to the upcoming release of Mongo 2.6 and features that needed to go into the existing driver with higher priority. Mongoid 5 will sunset Moped and use the 10gen driver 2.0.

The main thing left for backwards incompatible changes for Mongoid 4 is around the serialization of custom fields, which needs to be rewritten yet again due to a lot of unexpected beehaviour there. Once that's done the betas will start coming. Now that the holidays are over this will come soon.

Steve

Woot. Thanks so much! If there's an issue or PR for the serialization of custom fields, I'd love to follow along and/or help out where I can. :grin:

Phill Baker phillbaker referenced this issue in assaf/vanity
Closed

Add mongoid adapter #187

0 of 1 task complete
James Smith

Ready and willing to volunteer time to help with the custom field serialization, let me know how I can help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.