Skip to content

fix(dump): latin-1 fallback for project .env - #8444

Closed
Tianworld wants to merge 1 commit into
NousResearch:mainfrom
Tianworld:fix/dump-project-env-encoding-fallback
Closed

fix(dump): latin-1 fallback for project .env#8444
Tianworld wants to merge 1 commit into
NousResearch:mainfrom
Tianworld:fix/dump-project-env-encoding-fallback

Conversation

@Tianworld

Copy link
Copy Markdown
Contributor

Problem\n\hermes dump\ loads ~/.hermes/.env\ with a latin-1 fallback after UTF-8, but the repository root .env\ was opened with UTF-8 only. On Windows, .env\ files edited in Notepad are often cp1252; that could raise \UnicodeDecodeError\ and leave project keys out of the pasted support bundle.\n\n## Change\nMirror the same try/UTF-8 / except/latin-1 pattern for the project .env, only when the file exists.

Made with Cursor

hermes dump loaded ~/.hermes/.env with UTF-8/latin-1 fallback but the repo-root .env used UTF-8 only, so Windows cp1252 project files could raise UnicodeDecodeError and skip keys in support output.

Made-with: Cursor
@alt-glitch alt-glitch added type/bug Something isn't working P3 Low — cosmetic, nice to have comp/cli CLI entry point, hermes_cli/, setup wizard area/config Config system, migrations, profiles labels Apr 28, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

Likely duplicate of #8415 — same .env UTF-8/latin-1 fallback for dump command.

@teknium1

Copy link
Copy Markdown
Contributor

Closing as already fixed on main.

Triage notes (high confidence):
hermes_cli/dump.py:200-204 on main uses load_hermes_dotenv(project_env=...) which internally retries with latin-1 (env_loader.py:122-126). The project .env fallback path is already encoding-tolerant.

If you still see this on the latest version, please reopen with reproduction steps.

(Bulk-closed during a CLI triage sweep.)

@teknium1 teknium1 closed this May 24, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/config Config system, migrations, profiles comp/cli CLI entry point, hermes_cli/, setup wizard P3 Low — cosmetic, nice to have type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants