Repository navigation
Releases
Releases · omerdocs/lscw
v1.2.0 - Guest Mode aware warming
Fixed
- Sites without LiteSpeed Guest Mode no longer get uncached page renders.
guest.vary.phphands out a guest vary cookie even when Guest Mode is off, but LiteSpeed never stores requests carrying it — so on those sites (LiteSpeed's default) every desktop and mobile "full" request was a full, uncached page render that warmed nothing. Measured on a shared host: 6 requests and ~34 s per URL before, 1–2 requests and ~1.5 s per URL now. - LSCW no longer crashes on start when
richisn't installed (ImportError: cannot import name 'Live', present since 1.1.0).richis optional again, as documented. Accept-Encodingadvertisesbronly whenbrotliorbrotlicffiis installed. Without a decoder a brotli-compressed body couldn't be read, which silently broke the HTML inspection (inline vary value, Guest Mode check).
Added
--vary {auto,on,off}(defaultauto): the vary-keyed phases run only when the page carries LiteSpeed's Guest Mode script — the same script that makes a real browser callguest.vary.php.onforces them,offdisables them. Skipped phases are reported asoff.- Guest Mode detection is reported per run (
guest mode detected on X · not on Y). - Shared mobile copy detection: when the desktop request was a
MISSand the mobile request right after it is already aHIT, the URL is reported as sharing one copy (LiteSpeed "Cache Mobile" off), with a hint to use--no-mobile. requirements.txt; offline unit tests (python -m unittest discover -s tests -t .); GitHub Actions workflow running them on Linux and Windows.- Banner rows for
varyandbrotli.
Changed
--sitemap-uanow defaults tobrowser. A spoofed Googlebot is blocked wherever Googlebot is verified (reverse DNS, CDN verified-bot rules);--sitemap-ua googlebotis still available.- README: what each cache bucket depends on (Guest Mode, Cache Mobile), Windows commands (
python/pyinstead ofpython3), virtual environment setup, new troubleshooting entries.
Full changelog: v1.1.0...v1.2.0
v1.1.0 — Modular release
Architecture
- Project restructured from a single script into a Python package:
config,utils,ui,state,network,warmer,runner,cli. - Two entry points:
python3 lscw.py ...orpython3 -m lscw ...
Fixed
- Checkpoint now records every completed URL (previously ~90% of
progress could be lost on interruption); file writes are atomic. - Ctrl+C is handled gracefully: progress saved, exit code 130,
continue with--resume. - Adaptive delay is now enforced in parallel mode (
--workers > 1);
submissions are throttled so workers cannot stampede the server. - One HTTP session per worker thread (previously one per URL) and
all sessions are closed on exit. - HTTP 4xx/5xx responses (including 429) are treated as failures,
excluded from the checkpoint and sent to the auto-retry pass. - Retry results replace the originals, so summary stats are no
longer double-counted. - Crashed worker threads are recorded as errors instead of
silently disappearing.
Security
- URLs that do not belong to the
--sitehost are filtered out;
a malicious or misconfigured sitemap can no longer make the tool
send requests to third-party domains. - Off-site redirects are detected and skipped (
ext →). - Rich markup / terminal escape injection via URLs is prevented.
- Self-defeating
Cache-Control: no-cacherequest headers removed.
Added
--sitemap-ua {googlebot,browser}option for sitemap fetching.- Gzip-compressed sitemap support (
.xml.gz), CDATA and XML-entity
handling, and a 200-document crawl safety cap. - Pre-flight check now aborts on any 4xx with a WAF hint on 401/403.
- Summary reports mobile buckets separately and counts HTTP 429
responses.
UI
- Terminal interface redesigned: titled minimal panels (config,
Progress, Recent results, Summary), semantic-only colors, live
desktop + mobile counters, per-URL five-phase result columns.