-
Notifications
You must be signed in to change notification settings - Fork 105
Troubleshooting
Tier: Beginner
Common errors and fixes. When in doubt, also check the Discussions Q&A category — many issues have been hashed out there.
The default prebuilt binary uses CPU instructions some older x86_64 CPUs don't support. Switch to the portable subvariant:
| Standard | Portable |
|---|---|
qsv |
qsvp |
qsvlite |
qsvplite |
qsvdp |
qsvpdp |
Download from releases. Apple Silicon / Windows-on-ARM / IBM Power / s390x are unaffected.
qsv binaries are signed with an ad-hoc signature. Either:
xattr -d com.apple.quarantine qsv…or right-click the binary → Open → confirm in the Gatekeeper dialog. See Apple's Gatekeeper docs.
The MSI Easy Installer adds qsv to your PATH — but only for new terminals. Close and reopen your terminal after install. If still not found, the installer may have failed; check the install log.
The binary's enabled features depend on the build. Run qsv --version to see them — package-manager builds differ from the official prebuilt binaries. For the full feature set, install the prebuilt or build from source with -F all_features. See Binary Variants.
Not in the prebuilt — musl builds are cross-compiled and can't statically link Luau. Build from source on your musl distro (Alpine, Void, …) with cargo build --release --locked --bin qsv -F all_features.
The input isn't UTF-8. Two paths:
# Path A: Lossy normalization (substitute � for invalid bytes)
qsv input --encoding-errors replace messy.csv > utf8.csv
# Path B: Proper transcoding (recommended)
iconv -f ISO-8859-1 -t UTF-8 messy.csv -o utf8.csv
qsv input utf8.csv > clean.csvqsv input is lossy, not transcoding-correct. Use iconv first for known-source encodings. See Transform & Reshape → input.
# Explicit
qsv stats --delimiter ';' data.ssv
# Or: tell qsv to sniff every input
export QSV_SNIFF_DELIMITER=1
qsv stats data.weird-delimFor a one-off normalization to comma:
qsv fmt --out-delimiter ',' data.weird > data.csvThe CSV has rows of inconsistent width. Fix with:
qsv fixlengths ragged.csv > fixed.csvOr pass --flexible to commands that accept it (count --flexible).
Strip with:
qsv input --trim-headers bom.csv > clean.csvFor generating Excel-friendly CSVs with a BOM:
QSV_OUTPUT_BOM=1 qsv stats data.csv --output stats_excel.csvqsv index --force data.csvOr auto-refresh by setting QSV_AUTOINDEX_SIZE=<bytes> — see Performance Tuning.
Smart commands (frequency, validate, schema, …) consume <file>.stats.csv.data.jsonl, not <file>.stats.csv. Regenerate with:
qsv stats --stats-jsonl <file>Or set QSV_STATSCACHE_MODE=force. See Stats Cache & Caching.
Polars commands (sqlp, joinp, pivotp) inferred a column as Int64 but a later row has 12.5. Fix:
qsv schema --polars --force data.csv
# Hand-edit data.pschema.json: change the column's dtype to Float64Polars commands pick up the corrected .pschema.json automatically.
In-memory commands (🤯) — sort, dedup, reverse, table, transpose, pragmastat, stats --everything — can OOM on huge files. Three fixes:
-
Switch to the streaming variant:
-
Enable the pre-flight memory check:
export QSV_MEMORY_CHECK=1
export QSV_FREEMEMORY_HEADROOM_PCT=10- Constrain
stats/frequencychunk memory:
export QSV_STATS_CHUNK_MEMORY_MB=2048
export QSV_FREQ_CHUNK_MEMORY_MB=1024See Recipe: Larger-than-RAM CSV.
Pre-populate the stats cache so frequency knows the column is ALL_UNIQUE and short-circuits it:
qsv stats --cardinality --stats-jsonl data.csv
qsv frequency data.csvOr switch to the heavy-hitters mode:
qsv frequency --sketch-method frequent_items --sketch-map-size 16384 data.csv--infer-dates only checks columns whose names match the --dates-whitelist patterns (default: sniff). To force date inference on a column:
qsv stats --infer-dates --dates-whitelist 'mydate,timestamp,created_at' data.csvRegex is case-sensitive by default. Add -i:
qsv search -i 'brooklyn' data.csvFor non-ASCII characters, enable Unicode mode:
QSV_REGEX_UNICODE=1 qsv search 'café' data.csv(Unicode mode is slower; off by default.)
Likely a rate limit. Check the report:
qsv fetch URL data.csv --report > report.tsv
qsv frequency --select status report.tsvAdd --rate-limit N to throttle, or --disk-cache to dedupe repeated calls. See Recipe: Fetch & Cache.
Recent qsv versions fix several Excel edge cases. Run qsv --version and update if you're on an older release. The 20.0.0 changelog has the full list of excel fixes.
The luau feature isn't enabled in qsvlite / qsvdp and isn't available in musl prebuilds. Install the standard qsv or qsvpy* variant, or build from source. See Binary Variants.
qsv --version
qsv --envlistPaste both in your Discussions / Issues post.
export QSV_LOG_LEVEL=debug
export QSV_LOG_DIR=./qsv-logs
qsv stats data.csv
ls qsv-logs/See docs/Logging.md.
- Questions / how-to: Discussions Q&A
- FAQ-worthy: Discussions FAQ
- Confirmed bugs: Issues
- Security: see SECURITY.md
Always include qsv --version and qsv --envlist output, plus a minimal reproducer.
qsv — GitHub · Releases · Discussions · qsv pro · Try it online · Benchmarks · datHere · DeepWiki · Dual-licensed MIT / Unlicense
Edit this page: Contributing to the Wiki
Home · Why qsv? · Tier legend
- All Commands (index)
- Selection & Inspection
- Transform & Reshape
- Aggregation & Statistics
- Joins & Set Ops
- SQL & Polars
- Validation & Schema
- Conversion & I/O
- Geospatial
- HTTP & Web
- Scripting (Luau / Python)
- Indexing, Compression & Diff
- AI & Documentation