mirror of
https://github.com/MadsLorentzen/ai-job-search.git
synced 2026-11-02 13:12:50 +00:00
fix(salary): accept BOM-prefixed UTF-8 data files (#602)
* fix(salary): accept BOM-prefixed UTF-8 data files Fixes #594. Thanks to @rahul05ranjan for reporting the failure and identifying the decoder change. * docs(changelog): entry for #602 Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com> --------- Co-authored-by: Mads Lorentzen <madslorentzen_17@hotmail.com> Co-authored-by: Claude Fable 5.1 <noreply@anthropic.com>
This commit is contained in:
3 files changed
+57
-1
No files matched your search
+1
-1
@@ -149,7 +149,7 @@ def read_raw_data():
|
||||
print("step will be skipped during /apply.", file=sys.stderr)
|
||||
sys.exit(1)
|
||||
try:
|
||||
with open(DATA_FILE, "r", encoding="utf-8") as f:
|
||||
with open(DATA_FILE, "r", encoding="utf-8-sig") as f:
|
||||
data = json.load(f)
|
||||
except json.JSONDecodeError as exc:
|
||||
fail_data_error(f"invalid JSON at line {exc.lineno}, column {exc.colno}: {exc.msg}")
|
||||
|
||||
Reference in new issue
Block a user