[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
This commit is contained in:
parent
899465ed80
commit
11330b8de5
2 changed files with 7 additions and 4 deletions
|
|
@ -344,9 +344,7 @@ def _scan_models_dir(models_dir: Path, *, limit: int | None = None) -> List[Loca
|
|||
# local pipeline dir, so admit it here too (task tagging then classifies it via
|
||||
# _local_is_diffusers); otherwise it is hidden from the On Device picker.
|
||||
has_pipeline_index = (child / "model_index.json").is_file()
|
||||
has_model_files = (
|
||||
has_gguf or has_non_gguf_weights or has_config or has_pipeline_index
|
||||
)
|
||||
has_model_files = has_gguf or has_non_gguf_weights or has_config or has_pipeline_index
|
||||
except OSError:
|
||||
# Skip unreadable children rather than failing the scan.
|
||||
continue
|
||||
|
|
|
|||
|
|
@ -292,7 +292,12 @@ def test_generate_publishes_progress_before_lora_resolution(monkeypatch):
|
|||
|
||||
seen: dict = {}
|
||||
|
||||
def _resolve(active, *, hf_token = None, cancel_event = None):
|
||||
def _resolve(
|
||||
active,
|
||||
*,
|
||||
hf_token = None,
|
||||
cancel_event = None,
|
||||
):
|
||||
# Mid-setup: the in-flight generation must already be reported as active.
|
||||
seen["progress"] = b.generate_progress()
|
||||
return []
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue