func shouldDisable()

in Sources/XCRemoteCache/Dependencies/CacheModeController.swift [106:121]


    func shouldDisable(for commit: RemoteCommitInfo) -> Bool {
        guard case .available(let commitValue) = commit else {
            return true
        }
        do {
            let rawDependencies = try dependenciesReader.readFilesAndDependencies()
            if let commitToSkip = rawDependencies[FileDependenciesWriter.skipForShaKey] {
                return commitToSkip.contains(commitValue)
            }
        } catch {
            // Gracefully don't disable a cache
            // That may happen if building a target for the first time
            debugLog("Couldn't verify if should disable RC for \(commitValue).")
        }
        return false
    }