Hacktoberfest 2026: le issue che i maintainer hanno segnato per ottobre, aperte e adatte ai principianti. Sfoglia le issue Hacktoberfest

tooling: mise run install fails when core.hooksPath is set outside the repo (prek hook install is fatal)

Aperta Adatta ai principianti
#968 0 commenti 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
2/5
Tempo stimato
1-3 ore
Idoneità per principianti
82/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
git, python, typescript
Ambito
tooling

Direzione di ricerca

Leggi le definizioni delle attività mise nella directory principale per install e hooks:install, quindi riproduci il problema impostando core.hooksPath globalmente ed esegui mise run install. Verifica che l’installazione delle dipendenze venga completata e che l’attività termini correttamente quando l’installazione degli hook non è disponibile; hooks:install deve rimanere disponibile come percorso per i collaboratori.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Component: CDK / infrastructure (repo tooling: mise run install)

Describe the bug

The root install task ends with prek install --prepare-hooks. On machines where core.hooksPath is set at global or system scope (common on managed corporate machines that ship their own git hooks), prek refuses:

error: Refusing to install hooks because `core.hooksPath` is configured outside this repository.
[//:install] ERROR task failed

Because it is the last command of install, the whole task fails even though the Yarn workspaces and the agent's Python environment were installed successfully. Anyone who only wants to deploy (not contribute) is blocked by a contributor-only step, and the documented remedy in CONTRIBUTING.md (git config --unset-all core.hooksPath) is often not something they are allowed to do on a managed machine.

Expected behavior

mise run install succeeds and installs dependencies. Hook installation is either skipped with a clear warning when core.hooksPath is owned elsewhere, or split into its own task (hooks:install already exists).

Current behavior

mise run install exits non-zero after installing all dependencies, so scripts and guides that run it treat installation as failed.

Reproduction steps

  1. git config --global core.hooksPath /some/other/dir (or a system-level equivalent).
  2. Fresh clone, mise run install.
  3. Observe the failure from prek install --prepare-hooks.

Possible solution

Make the hook step non-fatal in install, e.g. prek install --prepare-hooks || echo "warning: git hooks not installed (core.hooksPath is set elsewhere); see CONTRIBUTING.md", and keep hooks:install as the strict path for contributors. Never change the user's global/system git config automatically.

Environment

  • macOS arm64 · mise 2026.10.18 · Commit 6dad935f (main)
Lingua principale
TypeScript
Stelle
165
Fork
50
Merge medio
6h 41m
PR unite (30g)
7

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di aws-samples/sample-autonomous-cloud-coding-agents

Tutte le issue di aws-samples/sample-autonomous-cloud-coding-agents

Issue simili

Altre issue su TypeScript

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.