Skip to content

Use UTF-8 encoding for reading config file.#970

Merged
richbeales merged 1 commit into
Significant-Gravitas:masterfrom
suclogger:fix-reading-config-file-encoding
Apr 13, 2023
Merged

Use UTF-8 encoding for reading config file.#970
richbeales merged 1 commit into
Significant-Gravitas:masterfrom
suclogger:fix-reading-config-file-encoding

Conversation

@suclogger

Copy link
Copy Markdown
Contributor

Background

Errors may occur when inputting Chinese characters into ai_setting.yaml due to encoding issues.

UnicodeDecodeError: 'gbk' codec can't decode byte 0xae in position 14: illegal multibyte sequence

Changes

Read config files with UTF-8 encoding.

Documentation

No need to document.

Test Plan

Tested locally & No need to add testcase.

PR Quality Checklist

  • My pull request is atomic and focuses on a single change.
  • I have thoroughly tested my changes with multiple different prompts.
  • I have considered potential risks and mitigations for my changes.
  • I have documented my changes clearly and comprehensively.
  • I have not snuck in any "extra" small tweaks changes

@richbeales richbeales merged commit d868143 into Significant-Gravitas:master Apr 13, 2023
@nponeccop nponeccop mentioned this pull request Apr 14, 2023
1 task
Yurak67 pushed a commit to Yurak67/Auto-GPT that referenced this pull request Apr 22, 2026
…g-config-file-encoding

Use UTF-8 encoding for reading config file.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants