MCPcopy Create free account
hub / github.com/NCAR/wrf-python / _get_cache

Function _get_cache

src/wrf/cache.py:150–163  ·  view source on GitHub ↗

Return the threadlocal cache. This is primarily used for testing. Returns: :class:`threading.local`

()

Source from the content-addressed store, hash-verified

148
149
150def _get_cache():
151 """Return the threadlocal cache.
152
153 This is primarily used for testing.
154
155 Returns:
156
157 :class:`threading.local`
158
159 """
160 global _local_storage
161
162 _shrink_cache()
163 return getattr(_local_storage, "cache", None)

Callers 2

runMethod · 0.90
test_thread_localMethod · 0.90

Calls 1

_shrink_cacheFunction · 0.85

Tested by 2

runMethod · 0.72
test_thread_localMethod · 0.72