[ruby/error_highlight] Prism added node_id and Node#breadth_first_search in the 1.0 release. These methods are required for Prism to be able to find the method from the backtrace.

https://github.com/ruby/prism/blob/main/CHANGELOG.md#100---2024-08-28

In practice you will likely only end up in this situation if you previously had pre-1.0 prism installed and upgrade Ruby to a version with Prism as the default parser.

https://github.com/ruby/error_highlight/commit/cb574daf62
This commit is contained in:
Adam Hess 2024-09-18 16:02:11 -07:00 committed by Hiroshi SHIBATA
parent 373f679e48
commit 4b1e852d3e
No known key found for this signature in database
GPG Key ID: F9CF13417264FAC2

View File

@ -85,7 +85,7 @@ module ErrorHighlight
# corresponding to the backtrace location in the source code.
def self.prism_find(location)
require "prism"
return nil if Prism::VERSION < "0.29.0"
return nil if Prism::VERSION < "1.0.0"
absolute_path = location.absolute_path
return unless absolute_path