Skip to content

Log targets marked out-of-date #1374

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
May 31, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions Sources/SemanticIndex/SemanticIndexManager.swift
Original file line number Diff line number Diff line change
Expand Up @@ -312,8 +312,15 @@ public final actor SemanticIndexManager {
// configured for macOS but not in target T configured for iOS.
let targets = await changedFiles.asyncMap { await buildSystemManager.configuredTargets(for: $0) }.flatMap { $0 }
if let dependentTargets = await buildSystemManager.targets(dependingOn: targets) {
logger.info(
"""
Marking targets as out-of-date: \
\(String(dependentTargets.map(\.description).joined(separator: ", ")))
"""
)
await preparationUpToDateTracker.markOutOfDate(dependentTargets)
} else {
logger.info("Marking all targets as out-of-date")
await preparationUpToDateTracker.markAllKnownOutOfDate()
// `markAllOutOfDate` only marks targets out-of-date that have been indexed before. Also mark all targets with
// in-progress preparation out of date. So we don't get into the following situation, which would result in an
Expand Down