Skip to content

Commit dbb4e96

Browse files
PurpleDoubleDclaude
andcommitted
chore: prevent setup.bat from luring end-users into dev mode (#30)
Reported as github issue #30 by @EnotikSergo: ran setup.bat expecting it to install the LU desktop app, ended up with `npm run dev` in Opera/Chrome, saw [vite] http proxy error: /system_stats ECONNREFUSED from a ComfyUI that was never installed. README described setup.bat as "Windows One-Click Setup" which reads as end-user install. Fixed on three scripts + the README: - setup.bat, setup.ps1, setup.sh now start with a prominent yellow banner explaining this is dev-mode (Vite + browser, fewer features) and linking to the GitHub Releases installer. Each script prompts Y/N before continuing so an accidental end-user can bail. - README's "Windows One-Click Setup" section was reframed as "For Contributors — Dev-Mode Setup" with an explicit "Just want to use the app? Download the installer above" blurb. Folded into v2.3.5 release alongside the LM Studio auto-detection fix and the Windows subprocess CREATE_NO_WINDOW cleanup. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
1 parent cb32b65 commit dbb4e96

5 files changed

Lines changed: 64 additions & 11 deletions

File tree

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@ All notable changes to Locally Uncensored are documented here.
77
### Fixed
88
- **LM Studio (and other openai-compat backends) now show up when Ollama is also running**`AppShell`'s post-onboarding detection only auto-enabled a backend when exactly one was detected. With two or more (the very common Ollama + LM Studio setup) it showed the `BackendSelector` modal but pre-enabled nothing. Users who dismissed the modal saw zero LM Studio models in the chat dropdown even though LM Studio was clearly running — looked from the outside like "LU doesn't recognize my models". Reported via Discord `#help-chat` on 2026-04-21. Fix: the first non-Ollama detected backend is always pre-enabled (Ollama is left untouched since it has its own provider slot); the selector stays as an educational picker so you can change which openai-compat backend is primary. Reproduced live with a mock LM Studio endpoint on port 1234 with Ollama also running, verified the fix against the same setup on the release binary. Five regression tests in `AppShell-backend-autoenable.test.ts`.
99
- **No more terminal flashes on Windows when LU kills subprocesses** — two Windows-branch `Command::new` spawns were missing `CREATE_NO_WINDOW`: the `taskkill` calls in `AppState::Drop` that tear down ComfyUI + Claude Code process trees on LU shutdown, and the `docker pull` / `docker run` in `search.rs` that installs SearXNG. Both briefly flashed a console window at the user. Now 100% of Windows-branch subprocess spawns carry the flag. LU itself never spawns LM Studio (only talks HTTP to a user-run instance), so the "no terminal when using LM Studio" guarantee was already true on that path; this tightens the peripheral surface.
10+
- **`setup.bat` / `setup.ps1` / `setup.sh` no longer mislead end-users into dev mode** — the scripts launched `npm run dev` (Vite + browser), which has fewer features than the installed Tauri app and produced confusing `[vite] http proxy error: /system_stats ECONNREFUSED` when ComfyUI wasn't installed yet. Reported via GitHub issue #30. Fix: all three setup scripts now start with a clear dev-mode banner, a link to the installer in Releases, and a one-key prompt to continue or exit. The README's "Windows One-Click Setup" section was also reframed as "For Contributors — Dev-Mode Setup" with an explicit pointer to the installer for end-users.
1011

1112
### Changed
1213
- Test suite 2161 → 2166 green (+5 regression tests for the backend-autoenable fix).

README.md

Lines changed: 8 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,12 @@ No cloud. No data collection. No API keys. Auto-detects 12 local backends. Your
3737

3838
## v2.3.5 — Current Release
3939

40-
**LM Studio auto-detection fix + Windows terminal-popup cleanup, 2166 Tests**
40+
**LM Studio auto-detection fix + Windows terminal-popup cleanup + clearer setup scripts, 2166 Tests**
4141

4242
### Critical Fixes (why you want this update)
4343
- **LU now recognizes your LM Studio models when Ollama is also running** — if the first-launch detection found 2+ local backends (the very common "Ollama + LM Studio" setup), the backend selector modal opened but no provider got auto-enabled. Users who dismissed the modal saw zero LM Studio models in the dropdown even though LM Studio was clearly running. Fixed: the first non-Ollama backend is always pre-enabled; the selector stays as an educational picker so you can still switch primaries. Reproduced live and verified against a real LM Studio-like endpoint.
4444
- **No more terminal flashes on Windows** — a couple of subprocess spawns on the Windows code path were missing `CREATE_NO_WINDOW`, so killing ComfyUI/Claude Code during LU shutdown or installing SearXNG briefly flashed a console window. 100% of Windows-branch spawns are now flagged.
45+
- **`setup.bat` / `setup.sh` no longer lure end-users into dev mode** — previously advertised as "one-click setup" but actually launched `npm run dev` in a browser. Now each script opens with a clear dev-mode banner, a link to the installer, and a one-key prompt to continue or exit. README's setup section reframed for contributors only.
4546

4647
### What's still in v2.3.5 from v2.3.4
4748
This is a hotfix release — v2.3.4's feature surface (chat-history persistence, Ollama 0.21 compat, Codex loop guard, stop-button instant, stale-chip fix, 12 backend auto-detection, Mobile Remote, Codex streaming, Agent Mode, ERNIE-Image, Qwen 3.6, 75+ downloadable models) is unchanged. Every fix from v2.3.4 and earlier still applies.
@@ -186,15 +187,18 @@ npm install
186187
npm run dev
187188
```
188189

189-
### Windows One-Click Setup
190+
### For Contributors — Dev-Mode Setup
191+
192+
> ⚠️ **Just want to use the app?** Grab the installer from [Releases](https://github.com/PurpleDoubleD/locally-uncensored/releases/latest) (the `.exe` or `.msi` in the **Download** section above). That gives you the full Tauri desktop app with auto-update. The commands below start LU in **browser dev-mode** — fewer features, Vite proxy noise, meant for contributing to the codebase.
190193
191194
```bash
192195
git clone https://github.com/PurpleDoubleD/locally-uncensored.git
193196
cd locally-uncensored
194-
setup.bat
197+
setup.bat # Windows — installs Node, Git, Ollama, then npm run dev
198+
# setup.sh # macOS / Linux equivalent
195199
```
196200

197-
Installs Node.js, Ollama, downloads an uncensored model, launches the app.
201+
Launches at `http://localhost:5173` in your default browser.
198202

199203
### Image & Video Generation
200204

setup.bat

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,20 @@
11
@echo off
2-
title Locally Uncensored - Setup
2+
title Locally Uncensored - Dev Setup
33
echo.
4+
powershell -NoProfile -Command ^
5+
"Write-Host '';Write-Host ' +---------------------------------------------------------------+' -F Yellow;Write-Host ' | This script starts Locally Uncensored in DEVELOPER mode. |' -F Yellow;Write-Host ' | It runs via Vite at http://localhost:5173 in your browser, |' -F Yellow;Write-Host ' | which has fewer features than the installed desktop app. |' -F Yellow;Write-Host ' | |' -F Yellow;Write-Host ' | Just want to USE the app? Download the installer instead: |' -F Yellow;Write-Host ' | https://github.com/PurpleDoubleD/locally-uncensored/releases |' -F Cyan;Write-Host ' +---------------------------------------------------------------+' -F Yellow;Write-Host ''"
6+
echo.
7+
choice /C YN /T 8 /D Y /M "Continue with developer setup? (Y/N, auto-Yes in 8s)"
8+
if errorlevel 2 (
9+
echo.
10+
echo Cancelled. Download the installer from:
11+
echo https://github.com/PurpleDoubleD/locally-uncensored/releases/latest
12+
pause
13+
exit /b 0
14+
)
415
echo.
516
powershell -NoProfile -Command ^
6-
"Write-Host ' ## ####### ###### ### ## ## ## ##' -F Magenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ## ## ## ## ## ## ## ## ####' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ######### ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ######## ####### ###### ## ## ######## ######## ##' -F Magenta;Write-Host '';Write-Host ' ## ## ## ## ###### ######## ## ## ###### ####### ######## ######## ########' -F Magenta;Write-Host ' ## ## ### ## ## ## ## ### ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ## ## #### ## ## #### ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ###### ## ## ###### ## ## ######## ###### ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' #### ## ## ###### ######## ## ## ###### ####### ## ## ######## ########' -F Magenta;Write-Host '';Write-Host ' Private, local AI. No cloud. No censorship.' -F DarkGray;Write-Host ' =================================================' -F Magenta"
17+
"Write-Host ' ## ####### ###### ### ## ## ## ##' -F Magenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ## ## ## ## ## ## ## ## ####' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ######### ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ######## ####### ###### ## ## ######## ######## ##' -F Magenta;Write-Host '';Write-Host ' ## ## ## ## ###### ######## ## ## ###### ####### ######## ######## ########' -F Magenta;Write-Host ' ## ## ### ## ## ## ## ### ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' ## ## #### ## ## #### ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ###### ## ## ###### ## ## ######## ###### ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##' -F DarkMagenta;Write-Host ' ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ## ##' -F Magenta;Write-Host ' #### ## ## ###### ######## ## ## ###### ####### ## ## ######## ########' -F Magenta;Write-Host '';Write-Host ' Private, local AI. No cloud. No censorship. (DEV MODE)' -F DarkGray;Write-Host ' =================================================' -F Magenta"
718
echo.
819

920
where node >nul 2>nul

setup.ps1

Lines changed: 22 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,27 @@
1-
# Locally Uncensored - Setup (PowerShell Wrapper)
2-
# This launches setup.bat in cmd.exe where it works correctly.
1+
# Locally Uncensored - Developer Setup (PowerShell)
2+
# Runs LU in dev-mode (Vite at localhost:5173). For the desktop app,
3+
# use the installer: https://github.com/PurpleDoubleD/locally-uncensored/releases
34

4-
$Host.UI.RawUI.WindowTitle = "Locally Uncensored - Setup"
5+
$Host.UI.RawUI.WindowTitle = "Locally Uncensored - Dev Setup"
56

7+
Write-Host ""
8+
Write-Host " +---------------------------------------------------------------+" -ForegroundColor Yellow
9+
Write-Host " | This script starts Locally Uncensored in DEVELOPER mode. |" -ForegroundColor Yellow
10+
Write-Host " | It runs via Vite at http://localhost:5173 in your browser, |" -ForegroundColor Yellow
11+
Write-Host " | which has fewer features than the installed desktop app. |" -ForegroundColor Yellow
12+
Write-Host " | |" -ForegroundColor Yellow
13+
Write-Host " | Just want to USE the app? Download the installer instead: |" -ForegroundColor Yellow
14+
Write-Host " | https://github.com/PurpleDoubleD/locally-uncensored/releases |" -ForegroundColor Cyan
15+
Write-Host " +---------------------------------------------------------------+" -ForegroundColor Yellow
16+
Write-Host ""
17+
$answer = Read-Host "Continue with developer setup? (y/N)"
18+
if ($answer -notmatch '^[Yy]') {
19+
Write-Host ""
20+
Write-Host "Cancelled. Download the installer from:" -ForegroundColor White
21+
Write-Host " https://github.com/PurpleDoubleD/locally-uncensored/releases/latest" -ForegroundColor Cyan
22+
Read-Host "Press Enter to exit"
23+
exit
24+
}
625
Write-Host ""
726
Write-Host ""
827
Write-Host " ## ####### ###### ### ## ## ## ##" -ForegroundColor Magenta

setup.sh

Lines changed: 20 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,35 @@
11
#!/bin/bash
22

3-
# Locally Uncensored — Setup Script (Linux/macOS)
4-
# One command to get everything running.
3+
# Locally Uncensored — Developer Setup (Linux/macOS)
4+
# Runs LU in dev-mode (Vite at localhost:5173). For the installed
5+
# desktop experience, build with `npm run tauri:build` or grab the
6+
# AppImage/deb/rpm from Releases once a build is posted for your OS.
57

68
set -e
79

810
PURPLE='\033[0;35m'
911
GREEN='\033[0;32m'
1012
YELLOW='\033[1;33m'
13+
CYAN='\033[0;36m'
1114
DIM='\033[2m'
1215
NC='\033[0m'
1316

1417
echo ""
18+
echo -e "${YELLOW} +---------------------------------------------------------------+${NC}"
19+
echo -e "${YELLOW} | This script starts Locally Uncensored in DEVELOPER mode. |${NC}"
20+
echo -e "${YELLOW} | It runs via Vite at http://localhost:5173 in your browser, |${NC}"
21+
echo -e "${YELLOW} | which has fewer features than a standalone desktop build. |${NC}"
22+
echo -e "${YELLOW} | |${NC}"
23+
echo -e "${YELLOW} | Just want to USE the app? Download the installer instead: |${NC}"
24+
echo -e "${CYAN} | https://github.com/PurpleDoubleD/locally-uncensored/releases |${NC}"
25+
echo -e "${YELLOW} +---------------------------------------------------------------+${NC}"
26+
echo ""
27+
read -p "Continue with developer setup? (y/N) " answer
28+
case "$answer" in
29+
[Yy]*) echo "" ;;
30+
*) echo -e "Cancelled. Download the installer from:\n ${CYAN}https://github.com/PurpleDoubleD/locally-uncensored/releases/latest${NC}"; exit 0 ;;
31+
esac
32+
1533
echo -e "${PURPLE}"
1634
echo " ╔═══════════════════════════════════════════╗"
1735
echo " ║ LOCALLY UNCENSORED ║"

0 commit comments

Comments
 (0)