A cache hit drops the symbolic links in a task's outputs
Mantenedores costumam responder em até 1 dia
Ninguém assumiu esta issue ainda.
Avaliação
- Dificuldade
- 4/5
- Tempo estimado
- 3-5 dias
- Facilidade para iniciantes
- 45/100
- Tipo de issue
- Bug
- Clareza
- Razoavelmente clara
- Status de atividade
- Ativa
- Stack de tecnologia
- rust
- Domínio
- build-system
Direção de pesquisa
Start with create_output_archive in crates/vt/src/session/cache/archive.rs and walk_glob_files in crates/vt/src/session/execute/glob.rs; the issue describes how both handle symbolic links. Reproduce with the provided task, then check the cache archive and glob behavior for links. Done when a cache hit restores links matched by an output glob; automatic tracking of created links is explicitly left open.
Escrita pelo modelo de indexação a partir do texto da issue.
Descrição
Written by an AI agent (Claude) on behalf of @jasonkuhrt.
A cache hit leaves out the symbolic links a task created in its outputs, so the replayed output differs from the one the task produced.
We hit it with Nitro's server build: its dependency tracer (nf3) writes server/node_modules/tslib -> .nf3/[email protected]. After a hit, the link is gone, and the replayed server resolves tslib outside its own output, or not at all.
Repro. A package with this script and task:
// make-link.mjs
import fs from 'node:fs';
fs.mkdirSync('dist/.store/pkg', { recursive: true });
fs.writeFileSync('dist/.store/pkg/index.js', 'export default 42;');
fs.symlinkSync('.store/pkg', 'dist/pkg');
// vite.config.ts
export default defineConfig({
run: {
tasks: {
build: {
command: 'node make-link.mjs',
cache: { output: [{ auto: true }, 'dist/**'] },
},
},
},
});
vp run build, rm -rf dist, vp run build again: the second run is a cache hit, dist/.store/pkg/index.js is back, and dist/pkg is missing.
Causes (at 0346c268):
create_output_archivereads each output withstd::fs::metadata, which follows links, and archives regular files only: a directory link is skipped, and a file link would be stored as a copy of its target.walk_glob_fileskeeps onlyis_file()entries, so anoutputglob never lists a link.- Automatic output tracking never sees a link being created: fspy has no interceptor for
symlink/symlinkat(preload interceptions, and the Linux syscall handler), norCreateSymbolicLinkWon Windows. So even with 1 and 2 fixed,{ auto: true }alone can't list a created link; it takes anoutputglob that matches it.
A fix for 1 and 2 follows in a PR. 3 is left open here.
- Linguagem predominante
- Rust
- Estrelas
- 480
- Forks
- 50
- Merge médio
- 1d 3h
- PRs com merge (30d)
- 62
Preparar o ambiente
Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.
- Sem Dockerfile nem arquivo Docker Compose
- Sem modelo de pull request
- Ler o guia de contribuição
Primeiros passos
- Leia a issue inteira e depois o guia de contribuição do projeto.
- Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
- Faça um fork do repositório e trabalhe em uma branch.
- Abra um pull request que referencie o número da issue.
Mais de voidzero-dev/vite-task
-
A task output archive larger than the remote cache server's request limit can never be storedAberta
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 45/100
voidzero-dev/vite-task#888 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 58/100
voidzero-dev/vite-task#886 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 3/5 1-2 dias Facilidade para iniciantes 72/100
voidzero-dev/vite-task#881 ·
Mantenedores costumam responder em até 1 dia
-
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
voidzero-dev/vite-task#879 ·
Mantenedores costumam responder em até 1 dia
-
vp run hangs after a failure when a cancelled task's detached descendant holds its IPC connectionAberta
Dificuldade 4/5 3-5 dias Facilidade para iniciantes 48/100
voidzero-dev/vite-task#878 ·
Mantenedores costumam responder em até 1 dia
Todas as issues de voidzero-dev/vite-task
Issues semelhantes
-
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 73/100
Mantenedores costumam responder em até 1 dia
-
C-bug needs-triage O-UEFI T-libs
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 78/100
Mantenedores costumam responder em até 1 dia
-
bug priority: P3 ready-for-agent
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 82/100
shep-pm/shep-kelpie#1332 ·
Mantenedores costumam responder em até 1 dia
-
enhancement
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 65/100
ramensoftware/windhawk#1156 · 2 comentários ·
-
area/cli complexity:trivial good first issue Stellar Wave test
Dificuldade 2/5 1-3 horas Facilidade para iniciantes 68/100
Externalize-Labs/externalize#23 ·
Mantenedores costumam responder em até 1 dia