diff options
author | Marcus Müller <mmueller@gnuradio.org> | 2021-05-26 22:08:44 +0200 |
---|---|---|
committer | mormj <34754695+mormj@users.noreply.github.com> | 2021-06-04 19:08:50 -0400 |
commit | 9d92ffbc091ce34bba6ea5624c7fe5fe130d5136 (patch) | |
tree | a79df78b6301d998d861eff73841aed8b12fa332 /grc/core/platform.py | |
parent | e2f152dd4c6d6bd9b3bc5986f7c13655fd2f6a61 (diff) |
GRC: cache now time-dependent, version-sensitive
Complete Cache will be discarded if current cache file
* has no version info
* version older than version in cacheversion.in (i.e. after an update)
Cached entry will be reloaded from yaml if
* missing
* cached-at property smaller than modification time of yaml file (half
second tolerance, due to inelegant floating point modification time
handling in python)
Also, a bit of debug logging.
Signed-off-by: Marcus Müller <mmueller@gnuradio.org>
Diffstat (limited to 'grc/core/platform.py')
-rw-r--r-- | grc/core/platform.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/grc/core/platform.py b/grc/core/platform.py index 02cb385e57..42d5b660c7 100644 --- a/grc/core/platform.py +++ b/grc/core/platform.py @@ -134,7 +134,7 @@ class Platform(Element): # converter.run() # logging.info('XML converter done.') - with Cache(Constants.CACHE_FILE) as cache: + with Cache(Constants.CACHE_FILE, version = self.config.version) as cache: for file_path in self._iter_files_in_block_path(path): if file_path.endswith('.block.yml'): |