Nx adapter: map files and test files to Nx projects from `nx graph`

Aberta
#112 0 comentários 0 reações 0 responsáveis Ver no GitHub

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
56/100
Tipo de issue
Funcionalidade
Clareza
Claramente especificada
Status de atividade
Ativa
Stack de tecnologia
node.js, typescript
Domínio
devtools, testing

Direção de pesquisa

Start with the adapter interface in src/repo/adapters/types.ts and trace how repository adapters assign test files and package dependencies. Check how verify and observe --no-send handle repository analysis before deciding where the Nx graph can be used safely. Add a small Nx fixture with one inferred and one explicit test target; done means ownership and dependency edges are covered, and graph failures follow the stated blocker behavior.

Escrita pelo modelo de indexação a partir do texto da issue.

Descrição

adapter enhancement help wanted

Part of #111.

  • Detect Nx: nx.json at the root and nx in the root manifest.
  • Run the repository's own Nx: node_modules/.bin/nx graph --file=<tmp>.json with NX_DAEMON=false, NX_NO_CLOUD=true and a timeout. Plugin-inferred targets (@nx/vite/plugin, @nx/jest/plugin) only exist after Nx evaluates its plugins, so reading project.json alone would miss them.
  • Running Nx executes plugin code. verify may do it. observe --no-send should use the graph only from a cache for the same tree, or with an explicit flag.
  • Contribute through the adapter interface (src/repo/adapters/types.ts):
    • project ownership of test files (testPackages, deepest project root wins);
    • implicitDependencies and Nx-detected project dependencies as package-level edges.
  • Blockers: Nx fails to produce a graph (global); a target with an executor DiffCI can't narrow (scoped to that project).
  • Fixture: a small Nx workspace with one inferred and one explicit test target.
Linguagem predominante
TypeScript
Estrelas
0
Forks
4
Merge médio
18h 41min
PRs com merge (30d)
48

Preparar o ambiente

Abrir no Codespaces

Inicia o contêiner de desenvolvimento do projeto no navegador, com a sua própria conta do GitHub.

Primeiros passos

  1. Leia a issue inteira e depois o guia de contribuição do projeto.
  2. Comente na issue dizendo que vai assumir — evita que duas pessoas façam o mesmo trabalho.
  3. Faça um fork do repositório e trabalhe em uma branch.
  4. Abra um pull request que referencie o número da issue.

Mais de DiffCI/core

Todas as issues de DiffCI/core

Issues semelhantes

Mais issues de TypeScript

Receba novas issues na sua caixa de entrada

Um resumo curto de issues do GitHub para quem está começando.