MCPcopy Index your code
hub / github.com/python/mypy / is_fresh

Method is_fresh

mypy/build.py:3032–3047  ·  view source on GitHub ↗

Return whether the cache data for this file is fresh.

(self)

Source from the content-addressed store, hash-verified

3030 self.ancestors = ancestors
3031
3032 def is_fresh(self) -> bool:
3033 """Return whether the cache data for this file is fresh."""
3034 # NOTE: self.dependencies may differ from
3035 # self.meta.dependencies when a dependency is dropped due to
3036 # suppression by silent mode. However, when a suppressed
3037 # dependency is added back we find out later in the process.
3038 # Additionally, we need to verify that import following options are
3039 # same for suppressed dependencies, even if the first check is OK.
3040 return (
3041 self.meta is not None
3042 and self.dependencies == self.meta.dependencies
3043 and (
3044 self.options.fine_grained_incremental
3045 or self.meta.suppressed_deps_opts == self.suppressed_deps_opts()
3046 )
3047 )
3048
3049 def mark_as_rechecked(self) -> None:
3050 """Marks this module as having been fully re-analyzed by the type-checker."""

Callers 2

find_stale_sccsFunction · 0.80

Calls 1

suppressed_deps_optsMethod · 0.95

Tested by

no test coverage detected