44
55
66class FirefoxStateOracle (StateOracle ):
7- @Cache .cache_in_db ('web_browser' , 'firefox' )
7+ # @Cache.cache_in_db('web_browser', 'firefox')
88 def find_commit_nb (self , commit_id : str ) -> int :
99 return PublicBrowserStateCache .firefox_get_commit_nb (commit_id )
1010
11- @Cache .cache_in_db ('web_browser' , 'firefox' )
11+ # @Cache.cache_in_db('web_browser', 'firefox')
1212 def find_commit_id (self , commit_nb : int ) -> str :
1313 return PublicBrowserStateCache .firefox_get_commit_id (commit_nb )
1414
15- @Cache .cache_in_db ('web_browser' , 'firefox' )
15+ # @Cache.cache_in_db('web_browser', 'firefox')
1616 def find_commit_nb_of_release (self , release_version : int ) -> int :
1717 return PublicBrowserStateCache .get_release_commit_nb ('firefox' , release_version )
1818
19- @Cache .cache_in_db ('web_browser' , 'firefox' )
19+ # @Cache.cache_in_db('web_browser', 'firefox')
2020 def find_commit_id_of_release (self , release_version : int ) -> str :
2121 return PublicBrowserStateCache .get_release_commit_id ('firefox' , release_version )
2222
@@ -36,7 +36,9 @@ def get_release_executable_download_urls(self, major_version: int) -> list[str]:
3636 def get_commit_url (self , commit_nb : int , commit_id : str ) -> str :
3737 return f'https://hg.mozilla.org/releases/mozilla-release/rev/{ commit_id } '
3838
39- @Cache .cache_in_db ('web_browser' , 'firefox' )
39+ # We don't cache this for firefox, since it is implicitly caches by PublicBrowserStateCache.
40+ # If we would, negative results for future executables remain stored even after the executable becomes available.
41+ # @Cache.cache_in_db('web_browser', 'firefox')
4042 def has_public_commit_executable (self , commit_nb : int ) -> bool :
4143 return PublicBrowserStateCache .firefox_has_executable_for (commit_nb = commit_nb )
4244
0 commit comments