MCPcopy Create free account
hub / github.com/aboutcode-org/scancode-toolkit / get_cache

Function get_cache

src/licensedcode/cache.py:392–410  ·  view source on GitHub ↗

Return a LicenseCache either rebuilt, cached or loaded from disk. If ``index_all_languages`` is True, include texts in all languages when building the license index. Otherwise, only include the English license texts and rules (the default)

(
    only_builtin=False,
    force=False,
    index_all_languages=False,
    additional_directory=None
)

Source from the content-addressed store, hash-verified

390
391
392def get_cache(
393 only_builtin=False,
394 force=False,
395 index_all_languages=False,
396 additional_directory=None
397):
398 """
399 Return a LicenseCache either rebuilt, cached or loaded from disk.
400
401 If ``index_all_languages`` is True, include texts in all languages when
402 building the license index. Otherwise, only include the English license
403 texts and rules (the default)
404 """
405 return populate_cache(
406 only_builtin=only_builtin,
407 force=force,
408 index_all_languages=index_all_languages,
409 additional_directory=additional_directory,
410 )
411
412
413def populate_cache(

Callers 10

generate_detailsFunction · 0.90
get_indexFunction · 0.70
get_licenses_dbFunction · 0.70
get_licensingFunction · 0.70
get_unknown_spdx_symbolFunction · 0.70
get_spdx_symbolsFunction · 0.70

Calls 1

populate_cacheFunction · 0.85

Tested by

no test coverage detected