Skip to content

Commit

Permalink
🐛 Re-check client managed files after ready (#1511)
Browse files Browse the repository at this point in the history
  • Loading branch information
misode authored Aug 1, 2024
1 parent 87841f6 commit 9ed6995
Showing 1 changed file with 11 additions and 6 deletions.
17 changes: 11 additions & 6 deletions packages/core/src/service/Project.ts
Original file line number Diff line number Diff line change
Expand Up @@ -377,12 +377,17 @@ export class Project implements ExternalEventEmitter {
this.tryClearingCache(uri)
}).on('ready', () => {
this.#isReady = true
// // Recheck client managed files after the READY process, as they may have incomplete results and are user-facing.
// const promises: Promise<unknown>[] = []
// for (const { doc, node } of this.#clientManagedDocAndNodes.values()) {
// promises.push(this.check(doc, node))
// }
// Promise.all(promises).catch(e => this.logger.error('[Project#ready] Error occurred when rechecking client managed files after READY', e))
// Recheck client managed files after the READY process, as they may have incomplete results and are user-facing.
const promises: Promise<unknown>[] = []
for (const { doc, node } of this.#clientManagedDocAndNodes.values()) {
promises.push(this.check(doc, node))
}
Promise.all(promises).catch(e =>
this.logger.error(
'[Project#ready] Error occurred when rechecking client managed files after READY',
e,
)
)
})
}

Expand Down

0 comments on commit 9ed6995

Please sign in to comment.