Skip to content

Query shell, remote ADBC, segfault fix, .* projection follow - #12

Merged
adsharma merged 7 commits into
mainfrom
query-shell-remote-adbc
Oct 25, 2026
Merged

adsharma merged 7 commits into
mainfrom
query-shell-remote-adbc

Conversation

@adsharma

Copy link
Copy Markdown
Contributor

Stacks five commits on top of 9e87560:

Query shell, Explore/Query sections, left pane with recents and remote ADBC

  • Left rail: Explore/Query icon switcher (also header, Ctrl-E/Ctrl-J, native + in-app menus), recents from ~/.bugscope_recent.json, Remote (ADBC) box for Arrow Flight grpc:// URIs.
  • Query section is an lbug-style shell: scrollback box tables, :help/:clear/:schema/:tables/:max_rows, dot-commands and /search, readline editing on every input, history in ~/.bugscope_shell_history. Graph-returning local Cypher replaces the explorer graph.
  • New adbc (Flight SQL client, remote edge/schema loads) and recents modules; arrow prettyprint + arrow-flight/tonic/tokio/futures deps.

Update vendored liblbug to 0.21.2 — refreshed prebuilt (lives in gitignored liblbug/; version reference updated).

Fix SIGSEGV on edgeless graphs in icebug FFI — node-only results (MATCH (n) RETURN n LIMIT 10) and isolated 1-hop neighborhoods packed empty CSR arrays that crashed inside icebug (signal 11, reproduced). PageRank now reports empty, Leiden a single community. Adds tests/analytics_edgeless.rs.

Explore follows . projections via bare-alias re-run* — RETURN a.*, b.* flattens to identity-free scalars, so the extractor found nothing and Explore kept the old graph. run_cypher re-runs the same read-only MATCH with bare aliases and merges, so the 10-edge subgraph shows. Quote/comment/bracket-aware rewriter; writes never re-execute (CREATE/… veto). Adds tests/star_projection.rs incl. a no-double-write test.

Use fixed-width font in the query shell — Menlo/Consolas/DejaVu Sans Mono per OS.

Verified with --release: cargo fmt --check clean, cargo clippy --all-targets -- -D warnings clean, full cargo test green except pre-existing gds_* env failures (algo LOAD fails in the test harness — fails identically on the base commit).

…e ADBC

Left rail gains an Explore/Query icon switcher (also in the header,
Ctrl-E/Ctrl-J, native + in-app menus), a recents list of local .lbdb
files persisted in ~/.bugscope_recent.json, and a Remote (ADBC) box
that connects to Arrow Flight endpoints (grpc://...) and lists them
alongside local databases.

The Query section is an lbug-style shell: scrollback with box tables,
:help/:clear/:schema/:tables/:max_rows, dot-commands and /search shared
with the explore box, readline editing (history, Ctrl-A/E/K/U/W,
Alt-B/F) on every input, and history persisted to
~/.bugscope_shell_history. Graph-returning local Cypher replaces the
explorer graph; remote Cypher reports row counts.

New modules adbc (Flight SQL prepared-statement client, table
formatting, remote edge/schema loads) and recents; arrow gains
prettyprint plus arrow-flight/tonic/tokio/futures deps.
Refresh liblbug.dylib/headers from the LadybugDB v0.21.2 release
(liblbug lives in gitignored liblbug/, so only the version reference
in the macOS staging script changes here).
Node-only Cypher results (MATCH (n) RETURN n LIMIT 10) and isolated
1-hop neighborhoods pack to empty CSR index arrays, which segfaulted
inside icebug when crossing the FFI via empty Arrow buffers. Guard
both in-process analytics entry points: PageRank reports no ranking
(matching the no-icebug-analytics fallback) and Leiden reports a
single community, mirroring its existing empty-links early return.
RETURN a.*, b.* flattens to identity-free scalar columns, so the
graph extractor found nothing and Explore kept showing the previous
graph. run_cypher now re-runs the same MATCH with bare aliases and
merges: MATCH (a)-[b]->(c) RETURN a.*, b.*, c.* LIMIT 10 shows its
10 edges. The rewriter is quote/comment/bracket aware (DISTINCT, AS,
backticked aliases, ORDER/LIMIT tails, subqueries) and never
re-executes anything that can write (CREATE/MERGE/DELETE/... veto
the fallback).
Box tables misalign under the proportional canvas font; render the
shell scrollback and input in Menlo/Consolas/DejaVu Sans Mono per OS.
The algo extension served upstream now expects a newer NetworKit
ABI than the 13.2 prebuilt; align the vendored headers/lib with 13.4.
The 13.2.0 icebug crate builds fine against it (verified locally).
INSTALL algo currently serves builds whose GDS calls segfault
against pinned lbug 0.21.2 (signal 11 in native code, killing the
whole harness — no graceful failure to assert on). Skip them in the
lint suite and the release GDS gate; in-process analytics coverage
(PageRank/Leiden over the same shapes) still runs everywhere.
@adsharma
adsharma merged commit 9428177 into main Oct 25, 2026
5 checks passed
@adsharma
adsharma deleted the query-shell-remote-adbc branch October 25, 2026 03:48
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant