Repository navigation
Conversation
psych's core_ext.rb defines `Object.yaml_tag(url)`, which calls `Psych.add_tag(url, self)` and so returns `url`. Without a signature, calls such as `Foo.yaml_tag "!foo"` cannot be resolved. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01EhUSLUimEYJyCZv8NdQGKb
apiology
added a commit
to iftheshoefritz/solargraph-rails
that referenced
this pull request
Oct 13, 2026
Psych's core_ext defines Object.yaml_tag, which returns the tag from Psych.add_tag; ruby/rbs lacks it until ruby/rbs#3226 ships. Not yet effective for subclasses: Solargraph's class-scope lookup never reaches Object's singleton methods, so Rails::Application .yaml_tag stays undefined until that is fixed. Claude-Session: https://claude.ai/code/session_01EhUSLUimEYJyCZv8NdQGKb Co-authored-by: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Claude: This PR was written by Claude Code on behalf of @apiology.
Problem: psych adds
Object.yaml_taginlib/psych/core_ext.rb, but the psych signatures do not declare it, so Steep rejects calls to it on any class and Solargraph can't infer their type.Solution: Declare
Object.yaml_tagas(String url) -> String. It callsPsych.add_tag(url, self), whose last expression,dump_tags[klass] = tag, returns the tag. This is the same from psych 5.0 (Ruby 3.2) through 5.2 (Ruby 3.4).🤖 Generated with Claude Code