archived-codacy / ruby-codacy-coverage

DEPRECATED Post coverage results to Codacy
12 stars 11 forks source link

Rails 5 support #12

Closed jalberto closed 8 years ago

jalberto commented 8 years ago

Dependencies need to be updated to work with rails 5

Bundler could not find compatible versions for gem "mime-types":
  In snapshot (Gemfile.lock):
    mime-types (= 3.0)

  In Gemfile:
    rails (< 5.1, >= 5.0.0.beta3) was resolved to 5.0.0.beta3, which depends on
      actionmailer (= 5.0.0.beta3) was resolved to 5.0.0.beta3, which depends on
        mail (>= 2.5.4, ~> 2.5) was resolved to 2.6.4, which depends on
          mime-types (< 4, >= 1.16)

    codacy-coverage was resolved to 0.3.1, which depends on
      rest-client (~> 1.8) was resolved to 1.8.0, which depends on
        mime-types (< 3.0, >= 1.16)

Running `bundle update` will rebuild your snapshot from scratch, using only
the gems in your Gemfile, which may resolve the conflict.
Bundler could not find compatible versions for gem "simplecov":
  In snapshot (Gemfile.lock):
    simplecov (= 0.11.2)

  In Gemfile:
    simplecov

    codacy-coverage was resolved to 0.0.1, which depends on
      simplecov (~> 0.10.0)
machadoit commented 8 years ago

Hey @jalberto

Thanks for letting us know, we created a ticket to review it, but in case you are interested, we do accept pull requests =)

andrebras commented 8 years ago

Hi @jalberto

Recent codacy-coverage versions have added rest-client as a runtime dependency and rest-client dependends on mime-types < 3.0.

So if you have mime-types locked to 3.0 which is fine for actionmailer/mail (mime-types < 4) breaks rest-client dependencies (mime-types < 3.0)!!

Try installing mime-types 2.99.1 manually, which is good for both, rest-client and mail. Or open your Gemfile.lock, remove references to mime-types (= 3.0) save and blundle again.

Perfect solution would be to update rest-client but this is not so easy, latter releases droped support to ruby 1.9. This is something that @machadoit will have to think about and it depends on what their plattform plans to support!

Hope it helps.

machadoit commented 8 years ago

Thanks for your feedback @andrebras,

We still don't know when we'll be able to fit the Rails 5 support in our sprints, but I will keep you posted! =)

jalberto commented 8 years ago

thanks @andrebras for the expanded explanation. @machadoit this is not a simple rails5 problem, is about outdated dependencies, I cannot use this gem in any of my new projects using the latest stable version of mime-types (sinatra, PORO, etc)

Downgrading mime-types is not an option as it will broke lot of stuff.

My suggestion will be, keep a "legacy" tag for people still using ruby < 1.9 then create a new version without rest-client, just using standard net lib

machadoit commented 8 years ago

Hey @jalberto @andrebras

As suggested I released a new version for ruby > 1.9 and without rest-client dependency. Let me know if it works well for you guys!

https://github.com/codacy/ruby-codacy-coverage/releases/tag/1.0.0

jalberto commented 8 years ago

Seems to post correctly data to Codacy :) (still waiting to see results in codacy though)

Thanks!