Created
September 12, 2012 02:14
-
-
Save zdrummond/3703781 to your computer and use it in GitHub Desktop.
Backtrace of class method breakpoint failure
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| [4] pry(Control::Job)> _pry_.hooks.errors | |
| => [#<TypeError: bind argument must be an instance of Control::Object>] | |
| [5] pry(Control::Job)> _pry_.last_exception = _pry_.hooks.errors.first | |
| => #<TypeError: bind argument must be an instance of Control::Object> | |
| [6] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/bia/Pocoa_Rails/app/ops/control.rb @ line 159 @ level: 0 of backtrace (of 46). | |
| 154: raw = get_json "#{WEB_URL}/statuses/#{uuid}" | |
| 155: j = raw[:job_status] | |
| 156: new( j[:scope_id], j[:uuid], j[:time], j[:bucket], j[:manifest] ) | |
| 157: end | |
| 158: | |
| => 159: def self.list | |
| 160: raw = RestClient.get "#{WEB_URL}/statuses" | |
| 161: resp = JSON.parse raw, symbolize_names: true | |
| 162: resp.map do |h| | |
| 163: inner = h.values[0] | |
| 164: new(inner[:scope_id], inner[:uuid], inner[:time], inner[:bucket], inner[:manifest] ) | |
| [7] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/bia/Pocoa_Rails/app/ops/control.rb @ line 159 @ level: 1 of backtrace (of 46). | |
| 154: raw = get_json "#{WEB_URL}/statuses/#{uuid}" | |
| 155: j = raw[:job_status] | |
| 156: new( j[:scope_id], j[:uuid], j[:time], j[:bucket], j[:manifest] ) | |
| 157: end | |
| 158: | |
| => 159: def self.list | |
| 160: raw = RestClient.get "#{WEB_URL}/statuses" | |
| 161: resp = JSON.parse raw, symbolize_names: true | |
| 162: resp.map do |h| | |
| 163: inner = h.values[0] | |
| 164: new(inner[:scope_id], inner[:uuid], inner[:time], inner[:bucket], inner[:manifest] ) | |
| [8] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/.rvm/gems/ruby-1.9.3-p194/gems/pry-0.9.10/lib/pry/method.rb @ line 70 @ level: 2 of backtrace (of 46). | |
| 65: meth_name = b.eval('__method__') | |
| 66: if [:__script__, nil].include?(meth_name) | |
| 67: nil | |
| 68: else | |
| 69: method = begin | |
| => 70: new(b.eval("Object.instance_method(:method).bind(self).call(#{meth_name.to_s.inspect})")) | |
| 71: rescue NameError, NoMethodError | |
| 72: Disowned.new(b.eval('self'), meth_name.to_s) | |
| 73: end | |
| 74: | |
| 75: # it's possible in some cases that the method we find by this approach is a sub-method of | |
| [9] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/.rvm/gems/ruby-1.9.3-p194/gems/pry-0.9.10/lib/pry/method.rb @ line 70 @ level: 3 of backtrace (of 46). | |
| 65: meth_name = b.eval('__method__') | |
| 66: if [:__script__, nil].include?(meth_name) | |
| 67: nil | |
| 68: else | |
| 69: method = begin | |
| => 70: new(b.eval("Object.instance_method(:method).bind(self).call(#{meth_name.to_s.inspect})")) | |
| 71: rescue NameError, NoMethodError | |
| 72: Disowned.new(b.eval('self'), meth_name.to_s) | |
| 73: end | |
| 74: | |
| 75: # it's possible in some cases that the method we find by this approach is a sub-method of | |
| [10] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/.rvm/gems/ruby-1.9.3-p194/gems/pry-0.9.10/lib/pry/default_commands/whereami.rb @ line 27 @ level: 4 of backtrace (of 46). | |
| 22: whereami will instead output a brief description of the current | |
| 23: object. | |
| 24: BANNER | |
| 25: | |
| 26: def setup | |
| => 27: @method = Pry::Method.from_binding(target) | |
| 28: @file = target.eval('__FILE__') | |
| 29: @line = target.eval('__LINE__') | |
| 30: end | |
| 31: | |
| 32: def options(opt) | |
| [11] pry(Control::Job)> cat -ex | |
| Exception: TypeError: bind argument must be an instance of Control::Object | |
| -- | |
| From: /Users/zdrummond/.rvm/gems/ruby-1.9.3-p194/gems/pry-0.9.10/lib/pry/command.rb @ line 463 @ level: 5 of backtrace (of 46). | |
| 458: # This function will display help if necessary. | |
| 459: # | |
| 460: # @param [Array<String>] args The arguments passed | |
| 461: # @return [Object] The return value of `process` or VOID_VALUE | |
| 462: def call(*args) | |
| => 463: setup | |
| 464: | |
| 465: self.opts = slop | |
| 466: self.args = self.opts.parse!(args) | |
| 467: | |
| 468: if opts.present?(:help) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment