Clickhouse Js Node Troubleshooting

by ClickHouse2f6ec4b17a81No license544 starsListed Oct 8, 2026Updated Oct 8, 2026Repository updated 9 days ago

Troubleshoot and resolve common issues with the ClickHouse Node.js client (@clickhouse/client). Use this skill whenever a user reports errors, unexpected behavior, or configuration questions involving the Node.js client specifically — including socket hang-up errors, Keep-Alive problems, stream handling issues, data type mismatches, read-only user restrictions, proxy/TLS setup problems, or long-running query timeouts. Trigger even when the user hasn't precisely named the issue; vague symptoms like "my inserts keep failing" or "connection drops randomly" in a Node.js context are strong signals to use this skill. Do NOT use for browser/Web client issues.

Instructions onlySoftware Development
AI-generated overview

Troubleshoots common errors and configuration issues with the ClickHouse Node.js client (@clickhouse/client).

What it does
This skill routes reported symptoms of the ClickHouse Node.js client to nine reference files covering socket hang-ups, data type mismatches, read-only users, proxy pathname confusion, TLS, compression, logging, query parameters, and FORMAT clause errors. It guides the agent to state a diagnosis before the fix, flag version constraints, and ask only for missing information. It produces troubleshooting guidance and explanations rather than code changes or files.
When to use it
Use when a user reports errors, unexpected behavior, or configuration questions involving the ClickHouse Node.js client, including vague symptoms such as failing inserts or random connection drops. It applies to Node.js runtimes only, including Next.js Node runtime, and not to browser, edge, or @clickhouse/client-web usage.
Requirements
No scripts; instructions and reference markdown files only. The agent needs the user's client version for version-dependent fixes and may consult external ClickHouse documentation links.

ClickHouse Node.js Client Troubleshooting

Reference: https://clickhouse.com/docs/integrations/javascript

⚠️ Node.js runtime only. This skill covers the @clickhouse/client package running in a Node.js runtime exclusively — including Next.js Node runtime API routes, React Server Components, Server Actions, and standard Node.js processes. Do not apply this skill to browser client components, Web Workers, Next.js Edge runtime, Cloudflare Workers, or any usage of @clickhouse/client-web. For browser/edge environments, the correct package is @clickhouse/client-web.


How to Use This Skill

  1. Identify the issue — match symptoms to the Issue Index below and read the corresponding reference file.
  2. Lead with the diagnosis — explain what's likely causing the issue before giving the fix.
  3. Note version constraints — flag if a fix requires a minimum client version and check it against what the user provided.
  4. Ask only what's missing — if the fix is version-dependent and you don't know their version, ask; otherwise help immediately.

Issue Index

Identify the user's issue from the list below and read the corresponding reference file for detailed troubleshooting steps.

IssueSymptomsReference file
Socket Hang-Up / ECONNRESETsocket hang up, ECONNRESET, intermittent connection drops, long-running queries timing outreference/socket-hangup.md
Data Type MismatchesLarge integers returned as strings, decimal precision loss, Date/DateTime insertion failures, CANNOT_PARSE_INPUT_ASSERTION_FAILED inserting a UUID into a UInt128 columnreference/data-types.md
Read-Only User ErrorsErrors when using response compression with readonly=1 usersreference/readonly-users.md
Proxy / Pathname URL ConfusionWrong database selected, requests failing behind a proxy with a path prefixreference/proxy-pathname.md
TLS / Certificate ErrorsTLS handshake failures, certificate verification issues, mutual TLS setupreference/tls.md
Compression Not WorkingGZIP compression not activating for requests or responsesreference/compression.md
Logging Not Showing AnythingNo log output, need custom logger integrationreference/logging.md
Query Parameters Not InterpolatedParameterized queries not working, SQL injection concernsreference/query-params.md
FORMAT Clause / SHOW POLICIES ErrorsSyntax error from a duplicate FORMAT, or SHOW [ROW] POLICIES failing even with a format providedreference/query-format-clause.md

Still Stuck?

Source and attribution

Source:ClickHouse/agent-skillsinskills/clickhouse-js-node-troubleshootingat commit2f6ec4b

License: No license

Content belongs to its original authors. SourceWeft indexes it from a public repository.

Report or request removal

More from ClickHouse/agent-skills

Clickhouse Managed Postgres Rca

ClickHouse

Evidence-based root cause analysis workflow for performance issues on ClickHouse-managed Postgres instances.

DevOps & Cloud544updated 9 days ago

Clickhouse Best Practices

ClickHouse

Reviews ClickHouse schemas, queries, and ingestion strategies against 31 documented best-practice rules.

Data & Analytics544updated 9 days ago

Clickhouse Architecture Advisor

ClickHouse

Guides ClickHouse architecture decisions for specific workloads, labeling each recommendation as official, derived, or field.

Data & Analytics544updated 9 days ago

Chdb Sql

ClickHouse

Use when the user wants to run SQL — especially analytical SQL — on local files (parquet/csv/json), URLs, S3 paths, or remote databases (Postgres, MySQL, MongoDB, ClickHouse Cloud, Iceberg, Delta Lake) without setting up a server. Provides chDB — embedded ClickHouse SQL in Python with 1000+ functions, Session for stateful multi-step pipelines, parametrized queries, and cross-source joins via `s3()`, `mysql()`, `postgresql()`, `iceberg()`, `deltaLake()`, `remoteSecure()` table functions. TRIGGER when: user wants SQL on parquet/csv/files or across remote analytical sources; uses ClickHouse SQL features (window functions, windowFunnel, geoToH3, JSON path ops, Session, parametrized queries); imports `chdb` or calls `chdb.query()`. SKIP this skill for pandas-style DataFrame method-chaining (use chdb-datastore instead) or ClickHouse server administration.

Includes scripts
Awaiting classification544updated 9 days ago

Chdb Datastore

ClickHouse

Use chdb DataStore as a drop-in, ClickHouse-backed replacement for pandas to query, join and aggregate tabular data.

Includes scripts
Data & Analytics544updated 9 days ago