Coder Social home page Coder Social logo

bump-core's Issues

Unexpected behaviour for a conflicting Ruby gem with no version specified

For a Gemfile like this:

gem "rails", "4.2.7.1"
gem "web-console"

bump attempted to bump web-console (Gemfile.lock has 3.3.0) to 3.5.1, but could not as it requires rails >= 5. Instead, it updated web-console's dependencies and opened a confusing PR!

commit (origin/bump_web-console_to_3.5.1)
    Bump web-console to 3.5.1

    Bumps [web-console](https://github.com/rails/web-console) to 3.5.1.
    - [Release notes](https://github.com/rails/web-console/releases/tag/v3.5.1)
    - [Changelog](https://github.com/rails/web-console/blob/master/CHANGELOG.markdown)
    - [Commits](https://github.com/rails/web-console/compare/v3.3.0...v3.5.1)

diff --git a/Gemfile.lock b/Gemfile.lock
-    debug_inspector (0.0.2)
+    debug_inspector (0.0.3)

Exception when version not present in Python manifest

We've had an error via Sentry from bump:

JSON::ParserError: 765: unexpected token at ''
  from json/common.rb:156:in `parse'
  from json/common.rb:156:in `parse'
  from bump/update_checkers/python.rb:12:in `latest_version'
  from bump/update_checkers/base.rb:16:in `needs_update?'
  from /app/app/workers/dependency_updater.rb:62:in `update_dependency!'
  from /app/app/workers/dependency_updater.rb:33:in `perform'

It comes from here:

        @latest_version ||=
          begin
            url = "https://pypi.python.org/pypi/#{dependency.name}/json"
            JSON.parse(Excon.get(url).body)["info"]["version"]
          end
      end
# job args
{
  dependency: {'language': 'python', 'version': '1.0.13', 'name': 'sqlalchemy', 'previous_version': nil}, 
  dependency_files: [Filtered], 
  repo: {'commit': 'ca4cd6230ce6abcxxxxx24e42d89cfad6df3ffbb', 'name': 'gocardless/xxxx', 'language': 'python'}
}

I'm guessing that Excon.get(..) is returning an empty response, as https://pypi.python.org/pypi/SQLAlchemy/json includes this metadata?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.