Skip to content

chore: gitignore the code-scoped .install_method stamp - #65900

Closed
jtomek-strike48 wants to merge 1 commit into
NousResearch:mainfrom
jtomek-strike48:chore/gitignore-install-method
Closed

chore: gitignore the code-scoped .install_method stamp#65900
jtomek-strike48 wants to merge 1 commit into
NousResearch:mainfrom
jtomek-strike48:chore/gitignore-install-method

Conversation

@jtomek-strike48

Copy link
Copy Markdown

Summary

.install_method is a per-environment runtime stamp, not source. hermes_cli/config.stamp_install_method() writes it next to the running code to record how this install was set up (git/pip/docker/nixos), and detect_install_method() reads it back as the authoritative first signal.

Committing it would poison detection for every other install: a pip install of this tree would read a stale git stamp instead of falling through to its own detection, and the Docker image bakes its own value at build time. So it belongs in .gitignore.

Placed alongside the analogous .update-incomplete runtime breadcrumb, with a matching explanatory comment.

Changes

  • .gitignore: ignore .install_method

Test plan

  • git check-ignore .install_method → matches (.gitignore)
  • git status clean with a local .install_method present
  • No code paths touched — stamp_install_method() / detect_install_method() still read/write the physical file as before

The install-method stamp written by hermes_cli/config.stamp_install_method()
records how a specific install was set up ('git'/'pip'/'docker'/'nixos') next
to the running code, and is read back as the authoritative first signal in
detect_install_method(). It is per-environment runtime state, not source.

Committing it would poison detection for every other install (a pip install
of this tree would read a stale 'git' stamp instead of falling through to its
own detection), and the Docker image bakes its own value at build time. Ignore
it, alongside the analogous .update-incomplete runtime breadcrumb.
@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 duplicate This issue or pull request already exists labels Jul 16, 2026
@alt-glitch

Copy link
Copy Markdown
Collaborator

This was generated by AI during triage.

Duplicate of #54855 — both add .install_method to .gitignore to keep the code-scoped runtime stamp out of update/local-change handling. #51644 is related broader work.

@tonydwb tonydwb left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM! Good documentation in the gitignore comment explaining why this stamp should not be committed.

Reviewed by Hermes Agent

@tonydwb tonydwb left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review Summary

Verdict: Comment

Looks Good

  • Tiny chore: gitignore the .install_method stamp file (code-scoped)
  • No review concerns

Note

  • Prior COMMENT review exists; this is a confirmation review

Reviewed by Hermes Agent

@teknium1

Copy link
Copy Markdown
Contributor

Thanks for the focused fix. The premise holds on current main: hermes_cli/config.py:431-438 treats the code-tree .install_method as authoritative, hermes_cli/config.py:500-504 writes it there, and current .gitignore has no matching rule. This also protects the update autostash path at hermes_cli/main.py:6564.

Suggested changes

  • Add a hermetic regression test following tests/hermes_cli/test_update_autostash.py:859-903, using .install_method and the same git stash push --include-untracked invocation. That would preserve the intended updater behavior.

The member triage comment correctly notes that #54855 is a duplicate; selection between the two open contributions is a maintainer decision.

Automated hermes-sweeper review.

@teknium1 teknium1 added sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades sweeper:blast-moderate Sweeper blast radius: moderate — a subsystem or single platform area/install-update Installer, updater, packaging, wheels, doctor labels Jul 18, 2026
@jtomek-strike48
jtomek-strike48 deleted the chore/gitignore-install-method branch July 25, 2026 17:27
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 area/install-update Installer, updater, packaging, wheels, doctor comp/cli CLI entry point, hermes_cli/, setup wizard duplicate This issue or pull request already exists P3 Low — cosmetic, nice to have sweeper:blast-moderate Sweeper blast radius: moderate — a subsystem or single platform sweeper:risk-compatibility Sweeper risk: may break existing users, config, migrations, defaults, or upgrades type/bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants