Yeah, we need a real ObjectContext in order to do most of those checks, and it's fundamental to caching that some of the time we won't have that ObjectContext. So the check needs to go here.
We may need to {duplicate | break out into a separate function and call | whatever} some of those consistency checks (for lost objects, etc) in the maybe_handle_cache() function, though.