// Omitting CommitAllDocuments causes races between caches and assembly resolver protected virtual void CreateOrUpdateData([NotNull] IT4File t4File) { Locks.ExecuteOrQueueEx("T4 assembly reference invalidation", () => { if (!t4File.IsValid()) { return; } using var cookie = ReadLockCookie.Create(); PsiFiles.ExecuteAfterCommitAllDocuments(() => DoInvalidateAssemblies(t4File)); }); }