Repository navigation
Fix package resolution error to include file path (Fixes #1797) - #1799
Conversation
|
Nice fix! Will let @munificent take a look |
d221026 to
eae1f65
Compare
|
Hi @kevmoo, I've updated analysis_options_file.dart to bring the new error messages within the 80-character limit. Local analysis with dart analyze --fatal-infos now passes for this specific file. The remaining CI failures appear to be pre-existing use_null_aware_elements issues in files I haven't touched (like ast_extensions.dart and piece_factory.dart). Should I include a cleanup for those in this PR, or would you prefer to keep this strictly focused on the package resolution fix? |
|
#1804 for the lint fix feel free to just base your PR on mine if you want |
|
or just rebase on master – fix landed! |
aca29c2 to
30184aa
Compare
|
Rebased on master to include the recent lint fixes. Local analysis is now passing. |
kevmoo
left a comment
There was a problem hiding this comment.
I think this is straightforward enough for me to land. Thanks for making errors better!
|
Ha! Don't forget to format the formatter! |
30184aa to
4e4412e
Compare
|
@kevmoo ran the format command! :] |
|
pro tip: avoid force pushing when reviews have happened. Often folks want to see the delta between reviews! |
|
Got it @kevmoo! I actually thought it was the opposite, but thanks for the lesson, that makes total sense for the review process. Feel free to tag or assign me to any other issues you think would be a good fit. Happy to help out more! :] |
Fixes #1797
When
analysis_options.yamlfails to resolve a package URI in aninclude, the current error message does not indicate which file triggered the error. This makes debugging difficult in mono-repos with multiple analysis option files.This PR adds the file path (
optionsPath) to thePackageResolutionExceptionmessage.Changes:
readAnalysisOptionsto include$optionsPathin exception messages.analysis_options_file_test.dartto verify the path is present in the error string.Output:
Failed to resolve package URI "..." in include.Failed to resolve package URI "..." in include at "path/to/analysis_options.yaml".