aboutcode-org / aboutcode-org/scancode.io
RFC: Store symbols, DWARFs, package, function names, .js.map, and related
- Linguagem predominante
- Python
- Estrelas
- 215
- Forks
- 203
- Merge médio
- 4d 8h
- PRs com merge (30d)
- 6
Descrição
We need to design how to store symbols, DWARFs, Java package, or C# namespaces, function names, .js.map, and related symbols.
We can collect for instance DWARFs in SCTK with https://github.com/nexB/scancode-toolkit/issues/2422
We will soon support analyzing .js.map in SCIO with https://github.com/nexB/scancode.io/issues/650
In SCIO and later in SCTK and PurlDB, we need to have a proper way to store these symbols that are then used for devel_to_deploy mapping, indexed for matching for origin, and so on.
I suggest this approach:
A CodebaseResource (e.g., a file) would have one or more Symbol with these fields:
- `type`: one of path reference, symbol, string, etc.
- `data_source`: a code that describes what is the data source, like .js.map, DWARF, elf, Go pclntab, pdb, source code, etc.
- `symbol`: the value of the symbol as as tring
- `sequence_number`: the sequence of this symbol: starting at 1 for the first symbol of this type/data_source found in the file, and incremented in the order these are found.
For instance:
- `type`: "path_reference"
- `data_source`: ".js.map"
- `symbol`: "../../main/src/UiCaroussel.js"
- `sequence_number`: 1
Guia de contribuição
Avaliação
Esta issue ainda não foi avaliada.