MCPcopy Index your code
hub / github.com/nodejs/node / get_cache_key

Method get_cache_key

tools/inspector_protocol/jinja2/bccache.py:166–174  ·  view source on GitHub ↗

Returns the unique hash key for this template name.

(self, name, filename=None)

Source from the content-addressed store, hash-verified

164 """
165
166 def get_cache_key(self, name, filename=None):
167 """Returns the unique hash key for this template name."""
168 hash = sha1(name.encode('utf-8'))
169 if filename is not None:
170 filename = '|' + filename
171 if isinstance(filename, text_type):
172 filename = filename.encode('utf-8')
173 hash.update(filename)
174 return hash.hexdigest()
175
176 def get_source_checksum(self, source):
177 """Returns a checksum for the source."""

Callers 1

get_bucketMethod · 0.95

Calls 2

encodeMethod · 0.80
updateMethod · 0.65

Tested by

no test coverage detected