Skip to content

Local UI to run and train LLMs and diffusion models. Supports GGUF, MLX, Qwen3.8, DeepSeek-V4.1, MiniMax-H3, Gemma 4, FLUX and more.

Update studio.py

Roland Tannous874711912dfd
diff --git a/cli/commands/studio.py b/cli/commands/studio.py
index 45b2e4fd13a..c13de30ba08 100644
--- a/cli/commands/studio.py
+++ b/cli/commands/studio.py
@@ -294,7 +294,13 @@ def _build_llama_cpp():
typer.echo(" Building llama.cpp for GGUF inference...")
if llama_dir.exists():
- shutil.rmtree(llama_dir)
+ # necessary because shutil.rmtree fails on Windows because .git pack files are read-only
+ def _force_remove_readonly(func, path, exc_info):
+ """Clear read-only flag and retry — needed on Windows for .git pack files."""
+ import stat
+ os.chmod(path, stat.S_IWRITE)
+ func(path)
+ shutil.rmtree(llama_dir, onerror=_force_remove_readonly)
unsloth_home.mkdir(parents = True, exist_ok = True)
result = subprocess.run(