Conversation
- retrieve_chunks now extracts entries array from retrieve_relevant's Hash response instead of returning the raw Hash, preventing TypeError: no implicit conversion of Symbol into Integer on legionio knowledge query - health now guards against nil path by falling back to Legion::Settings.dig(:knowledge, :corpus_path) and returning success: false with a clear error when no path is available, preventing TypeError: no implicit conversion of nil into String on legionio knowledge health - bump to 0.6.7
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.
Summary
legionio knowledge querycrashed withTypeError: no implicit conversion of Symbol into Integer—retrieve_chunkswas returning the raw{ success:, entries:, count: }Hash fromretrieve_relevantinstead of extracting theentriesarray; downstream code iterated the Hash as key-value pairs and called[:symbol]on the resulting Array tupleslegionio knowledge healthcrashed withTypeError: no implicit conversion of nil into String— the CLI passespath: nilwhen--corpus-pathis omitted, which fell straight intoFind.find(nil); now falls back toLegion::Settings.dig(:knowledge, :corpus_path)and returns a clear{ success: false, error: 'corpus_path is required' }when no path is availableTest plan
bundle exec rspec— 190 examples, 0 failuresbundle exec rubocop— 0 offensesquery_spec.rb: stubsretrieve_relevantreturning a Hash and asserts sources array is correctly extractedmaintenance_spec.rb: covers nil path with no settings, nil path with nil settings value, and nil path with valid settings fallback