Element.__update_cache_keys() may traverse the same BUILD dependency graph multiple times while calculating weak and strict cache keys.
PR #2172 reduces this locally by materializing the dependency list once and reusing it for both calculations, but Element._dependencies() could be cached with something like @functools.cache.
Element.__update_cache_keys()may traverse the sameBUILDdependency graph multiple times while calculating weak and strict cache keys.PR #2172 reduces this locally by materializing the dependency list once and reusing it for both calculations, but
Element._dependencies()could be cached with something like@functools.cache.