Avoid initializing progress bars early (#18049)

## Summary

Resolves https://github.com/astral-sh/ty/issues/324.
This commit is contained in:
Ibraheem Ahmed 2025-05-12 15:07:55 -04:00 committed by GitHub
parent bdccb37b4a
commit 550b8be552
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
6 changed files with 53 additions and 39 deletions

View file

@ -18,8 +18,8 @@ use ty_ide::{goto_type_definition, hover, inlay_hints, MarkupKind};
use ty_project::metadata::options::Options;
use ty_project::metadata::value::ValueSource;
use ty_project::watch::{ChangeEvent, ChangedKind, CreatedKind, DeletedKind};
use ty_project::ProjectMetadata;
use ty_project::{Db, ProjectDatabase};
use ty_project::{DummyReporter, ProjectMetadata};
use ty_python_semantic::Program;
use wasm_bindgen::prelude::*;
@ -186,7 +186,7 @@ impl Workspace {
/// Checks all open files
pub fn check(&self) -> Result<Vec<Diagnostic>, Error> {
let result = self.db.check(&DummyReporter).map_err(into_error)?;
let result = self.db.check().map_err(into_error)?;
Ok(result.into_iter().map(Diagnostic::wrap).collect())
}