Cache refresh policies based on scancode CLI options/scancode output version updates

Aberta
#5,472 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
5/5
Tempo estimado
Mais de uma semana
Facilidade para iniciantes
15/100
Tipo de issue
Funcionalidade
Clareza
Precisa de esclarecimento
Status de atividade
Ativa
Stack de tecnologia
python
Domínio
tooling

Direção de pesquisa

The payload names no file or test, so start from the two linked threads: discussion r3948561703 on PR 5289 and issue 3941, which cover cache versioning. The open question is whether to hash the data fields and CLI options into the cache index path, and how stale-cache errors are handled. Maintainers need to settle that design before a patch is meaningful, so done means an agreed policy in the thread, not a code change yet.

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

Descrição

maintainers-only

From https://github.com/aboutcode-org/scancode-toolkit/pull/5289#discussion_r3948561703, as a follow up:

Should we include some functionality to re-compute the cache for a file based on data structure changes caused by different versions of scancode, or different CLI options used with different output data formats? There is some discussion on this at https://github.com/aboutcode-org/scancode-toolkit/issues/3941

We need to check that we atleast handle the errors resulting out of this. Additionally it would be nice to somehow include the data format versions in the index cache too, smartly avoiding cache recompute whenever possible.

Output data formats are not always changes based on scancode versions, and an update in the output data format version also doesn't correspond to updates in all the scanner output data. So we need to probably compute a hash based on all the data fields present for a particular scanner data based on the keys present in the mapping and include this in the index file path? This would cover both variations caused by scancode version changes and CLI options used.

Linguagem predominante
Python
Estrelas
2.7k
Forks
871
Merge médio
1d 10h
PRs com merge (30d)
3

Preparar o ambiente

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 aboutcode-org/scancode-toolkit

Todas as issues de aboutcode-org/scancode-toolkit

Issues semelhantes

Mais issues de Python

Receba novas issues na sua caixa de entrada

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