diff --git a/chasten/database.py b/chasten/database.py index 4be5e2df..3293497f 100644 --- a/chasten/database.py +++ b/chasten/database.py @@ -66,7 +66,6 @@ def enable_full_text_search(chasten_database_name: str) -> None: database["sources"].enable_fts( [ "filename", - "filelines", "check_id", "check_name", "check_description", diff --git a/chasten/filesystem.py b/chasten/filesystem.py index 3755ecc7..1af06532 100644 --- a/chasten/filesystem.py +++ b/chasten/filesystem.py @@ -229,7 +229,7 @@ def write_dict_results( # using indentation to ensure that JSON file is readable results_path_with_file = results_path / complete_results_file_name # use the built-in method from pathlib Path to write the JSON contents - results_path_with_file.write_text(results_json) + results_path_with_file.write_text(results_json, "utf-8") # return the name of the file that contains the JSON dictionary contents return complete_results_file_name @@ -293,7 +293,7 @@ def get_json_results(json_paths: List[Path]) -> List[Dict[Any, Any]]: # iterate through each of the provided paths to a JSON file for json_path in json_paths: # turn the contents of the current JSON file into a dictionary - json_dict = json.loads(json_path.read_text()) + json_dict = json.loads(json_path.read_text("utf-8")) # add the current dictionary to the list of dictionaries json_dicts_list.append(json_dict) # return the list of JSON dictionaries