[Portable] Everything in ComfyUI_windows_portable/ should be part of the git repository
- Dominant language
- Python
- Stars
- 133k
- Forks
- 15.7k
- Avg merge
- 1d 7h
- Merged PRs (30d)
- 158
Description
### Custom Node Testing
- [x] I have tried disabling custom nodes and the issue persists (see [how to disable custom nodes](https://docs.comfy.org/troubleshooting/custom-node-issues#step-1%3A-test-with-all-custom-nodes-disabled) if you need help)
### Expected Behavior
All files in `ComfyUI_windows_portable/` should be versioned in the git repository, with `python_embed(D)ed/` listed in `.gitignore` — exactly as any Python project handles `venv/`, or any JS project handles `node_modules/`:
```
ComfyUI_windows_portable/ ← git repo root
├── .gitignore ← contains: python_embeded/
├── python_embeded/ ← ignored by git, never touched by pulls
├── update/
│ ├── update_comfyui.bat ← versioned, kept up to date
│ └── update_comfyui_and_python_dependencies.bat
├── run_nvidia_gpu.bat ← versioned
├── run_cpu.bat ← versioned
└── ComfyUI/ ← submodule or subfolder
```
With this layout:
- `git pull` updates the launch scripts, the update scripts, and ComfyUI's code in one shot
- `python_embeded/` is never touched by git, because it is gitignored
- Bug fixes to `.bat` scripts actually reach users
- The update script can fix itself
### Actual Behavior
Only `ComfyUI/` is a git repository. Everything around it — launch scripts, update scripts — lives outside of version control:
```
ComfyUI_windows_portable/ ← NOT a git repo
├── ComfyUI/ ← git repo (only this)
├── python_embeded/
├── update/
│ ├── update_comfyui.bat
│ └── update_comfyui_and_python_dependencies.bat
├── run_nvidia_gpu.bat
├── run_nvidia_gpu_fast_fp16_accumulation.bat
└── run_cpu.bat
```
### Steps to Reproduce
This is a structural/design issue, not a runtime crash. But the consequences are easy to observe:
1. Install the Windows portable release
2. Wait a few months without reinstalling
3. Run `update_comfyui_and_python_dependencies.bat`
4. Notice that the update script itself is never updated — if it was buggy or outdated at install time, it stays that way forever
**The core problem: the update scripts can never update themselves.**
If `update_comfyui_and_python_dependencies.bat` contains a bug or becomes outdated, running it will never fix it — because it lives outside the repo it is supposed to update. A user who installed the portable version six months ago and runs the update script today may be running a stale, broken version of that very script without knowing it.
This is a self-defeating design: the update mechanism is not covered by the update mechanism.
The same applies to all `.bat` launch scripts. If their arguments, paths, or flags need to change, there is no way to deliver that change to existing installations.
### Debug Logs
```powershell
Blablabla
```
### Other
Current known consequences of this design:
- `update_comfyui_and_python_dependencies.bat` is widely reported as unreliable (see #5399). This is at least partly because it cannot be fixed through a normal update cycle.
- The Python environment and the codebase can silently drift out of sync after partial updates, with no recovery path short of a full reinstall.
- The `python_embeded` folder name is even misspelled (missing a `d`), a detail that has persisted across releases (see #6782), further suggesting this structure has never been seriously reviewed.
The root cause of a whole class of portable-version bugs is that the repository boundary is drawn in the wrong place. Moving it up one level, and gitignoring `python_embeded/`, would fix this with minimal migration effort and align the project with standard practices used by virtually every other Python-based tool distributed on Windows.
Contributor guide
Assessment
This issue has not been assessed yet.