Skip to content

Issue regarding reloading and custom dictionaries and code analysis #281

@antonioatom

Description

@antonioatom

Just migrated everything to the new .editorconfig but I ran into some problems

  1. As stated in the documentation the file should be the language name "en-US.dic" for example. This doesn't seem to work. I needed to change the name of the file to the one used in the global settings "en-US_User.dic". This is not clear in the documentation since it cleary states the dictionary should have the language name as the filename (it is also mentioned here: Files names for custom dictionaries #204)
  2. You state in the documentation that any changes done to the .editorconfig file might only be read if you reload the solution but this doesn't seem to be the case. Few scenarios:
  • Changing branch within visual studio where the .editorconfig and the dictionaries are the same: it will sometimes fail the spell checks like the custom dictionaries and ignored words are not setup. I know this to be the case because if I manually run the spell check and try to add a word to custom dictionary or ignored words it will use the global files and not the local files in the solution
  • Changing .editorconfig and closing and reopening the solution: new settings are not read forcing me to completely close visual studio and open it again to read those.
  1. Another problem is running manually the spell check in the entire solution shows no errors but running the code analysis on the solution shows some VSSpelll001 errors of words that are in the ignore file:
image image

Using VS 17.5.5. Extension version: 2023.5.8.0.

Current .editorconfig in the root of the solution

[*]
vsspell_section_id = 7c96fdaf1b6247398b8f206b0699cba2
vsspell_determine_resource_file_language_from_name = false
vsspell_additional_dictionary_folders_7c96fdaf1b6247398b8f206b0699cba2 = .\CodeAnalysis\Dictionaries
vsspell_dictionary_languages_7c96fdaf1b6247398b8f206b0699cba2 = en-US
vsspell_spell_check_as_you_type = true
vsspell_include_in_project_spell_check = true
vsspell_code_analyzers_enabled = true
vsspell_detect_doubled_words = true
vsspell_ignore_words_with_digits = true
vsspell_ignore_words_in_all_uppercase = true
vsspell_ignore_words_in_mixed_case = true
vsspell_ignore_format_specifiers = true
vsspell_ignore_filenames_and_email_addresses = true
vsspell_ignore_xml_elements_in_text = true
vsspell_treat_underscore_as_separator = true
vsspell_ignore_mnemonics = true
vsspell_ignored_character_class = None
vsspell_code_analyzer_ignore_xml_doc_comments = false
vsspell_code_analyzer_ignore_delimited_comments = true
vsspell_code_analyzer_ignore_standard_single_line_comments = false
vsspell_code_analyzer_ignore_quadruple_slash_comments = true
vsspell_code_analyzer_ignore_normal_strings = false
vsspell_code_analyzer_ignore_verbatim_strings = true
vsspell_code_analyzer_ignore_interpolated_strings = true
vsspell_code_analyzer_apply_to_all_c_style_languages = true
vsspell_ignored_words_7c96fdaf1b6247398b8f206b0699cba2 = File:CodeAnalysis\Dictionaries\Solution.sln.IgnoredWords.dic
vsspell_exclusion_expressions_7c96fdaf1b6247398b8f206b0699cba2 = (omitted for simplicity)
vsspell_cad_import_code_analysis_dictionaries = true
vsspell_cad_treat_unrecognized_words_as_misspelled = true
vsspell_cad_treat_deprecated_terms_as_misspelled = true
vsspell_cad_treat_compound_terms_as_misspelled = true
vsspell_cad_treat_casing_exceptions_as_ignored_words = false
vsspell_cad_recognized_word_handling = IgnoreAllWords
vsspell_ignored_classifications_7c96fdaf1b6247398b8f206b0699cba2 =  (omitted for simplicity)
vsspell_code_analyzer_ignore_if_compiler_generated = true
vsspell_code_analyzer_ignore_quadruple_slash_comments = true
vsspell_code_analyzer_ignore_verbatim_strings = true
vsspell_code_analyzer_ignore_identifier_if_all_uppercase = true

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions