Hacktoberfest 2026: los issues que los mantenedores marcaron para octubre, abiertos y aptos para principiantes. Explorar issues de Hacktoberfest

[Bug]: Server git tests sign fixture commits with the developer's key when run from the repo root

Abierto Apto para principiantes
#17,523 0 comentarios 0 reacciones 0 asignados Ver en GitHub

Los mantenedores suelen responder en 1 día

@Mnigos ya está trabajando en esto.

Desde el 10/10/2026.

  • #17787 de @Mnigos — abierto

Evaluación

Dificultad
2/5
Tiempo estimado
1-3 horas
Aptitud para principiantes
78/100
Tipo de issue
Error
Claridad
Bien especificado
Estado de actividad
Activo
Stack tecnológico
git, typescript, vite
Área
testing

Línea de trabajo

La solución es un cambio de configuración: el vite.config.ts raíz tiene setupFiles sin apps/server/src/testUtils/gitConfig.setup.ts, que apps/server/vite.config.ts ya carga. Empieza comparando los dos arrays de setupFiles. Luego reproduce el problema ejecutando apps/server/src/git/GitManager.test.ts desde la raíz del repositorio, con GIT_CONFIG_GLOBAL apuntando a una configuración que establezca commit.gpgsign=true. Está terminado cuando la suite pasa sin llamadas a gpg y las demás suites siguen ejecutándose sin cambios.

Escrito por el modelo de indexación a partir del texto del issue.

Descripción

Before submitting
  • I searched existing issues and did not find a duplicate.
  • I included enough detail to reproduce or investigate the problem.
Area

apps/server

Steps to reproduce
  1. Set commit.gpgsign = true in ~/.gitconfig (any GPG or SSH signer; mine is a YubiKey through gpg-agent).
  2. From the repo root, run a server git suite the way AGENTS.md describes:
    vp test run apps/server/src/git/GitManager.test.ts
Expected behavior

Fixture repositories ignore the developer's signing config. apps/server/src/testUtils/gitConfig.setup.ts exists to pin commit.gpgsign=false and tag.gpgsign=false for exactly this reason.

Actual behavior

Every fixture commit calls gpg. With a hardware key, that's a PIN/touch prompt every few seconds for the whole run. Without a usable signer, most of the suite fails.

The setup file is only registered in apps/server/vite.config.ts (setupFiles). Running from the repo root loads the root vite.config.ts instead, and its setupFiles only contains packages/shared/src/testing/longTempDir.ts. Agents running inside T3 Code run tests from the root, so an agent running server tests on a machine with signing enabled keeps prompting the user.

Measured with GIT_CONFIG_GLOBAL pointing at a config with commit.gpgsign=true and a gpg.program that logs and exits 1:

Tests gpg calls
root config as is 107 failed, 13 passed 107
setup file added to root setupFiles 120 passed 0

Adding ./apps/server/src/testUtils/gitConfig.setup.ts to the root setupFiles fixes it. It only sets GIT_CONFIG_* variables, so other suites are unaffected. Happy to send the 3-line PR.

Impact

Major degradation or frequent failure

Version or commit

101f8b2f55

Environment

macOS 26 (Darwin 25.6), git 2.56, GnuPG (MacGPG2) with a YubiKey

Workaround

Run from apps/server (cd apps/server && vp test run src/git/GitManager.test.ts), or export GIT_CONFIG_COUNT=1 GIT_CONFIG_KEY_0=commit.gpgsign GIT_CONFIG_VALUE_0=false.

Lenguaje dominante
TypeScript
Estrellas
24.8k
Forks
6.4k
Merge medio
12 h 40 min
PR fusionados (30 d)
322

Preparar el entorno

Abrir en Codespaces

Inicia el contenedor de desarrollo del proyecto en tu navegador, con tu propia cuenta de GitHub.

Primeros pasos

  1. Lee el issue completo y luego la guía de contribución del proyecto.
  2. Comenta en el issue que vas a ocuparte — evita que dos personas hagan lo mismo.
  3. Haz un fork del repositorio y trabaja en una rama.
  4. Abre un pull request que haga referencia al número del issue.

Más de pingdotgg/t3code

Todos los issues de pingdotgg/t3code

Issues similares

Más issues de TypeScript

Recibe los nuevos issues en tu correo

Un resumen breve de issues de GitHub para principiantes.