Repository Analysis

tursodatabase/libsql

libSQL is a fork of SQLite that is both Open Source, and Open Contributions.

1.5 Likely human-written View on GitHub
1.5
Adjusted Score
1.5
Raw Score
100%
Time Factor
2026-05-29
Last Push
16,792
Stars
C
Language
801,292
Lines of Code
1442
Files
1038
Pattern Hits
2026-05-31
Scan Date

Score History

Severity Breakdown

CRITICAL 14HIGH 0MEDIUM 42LOW 982

Pattern Findings

1038 matches across 12 categories. Click a row to expand file-level details.

Over-Commented Block967 hits · 897 pts
SeverityFileLineSnippet
LOWlibsql-sys/src/connection.rs421// unsafe impl<'a> Send for Connection<'a> {}
LOWlibsql-sys/src/connection.rs441// path: impl AsRef<std::path::Path>,
LOWlibsql-sys/src/connection.rs461// // the returned connection.
LOWlibsql-sys/src/connection.rs481// }
LOWlibsql-sys/src/connection.rs501// crate::ffi::sqlite3_close(self.conn as *mut _);
LOWlibsql-sqlite3/ltmain.sh1# Generated from ltmain.m4sh.
LOWlibsql-sqlite3/ltmain.sh21# WITHOUT ANY WARRANTY; without even the implied warranty of
LOWlibsql-sqlite3/ltmain.sh41# --quiet, --silent don't print informational messages
LOWlibsql-sqlite3/ltmain.sh61# include the following information:
LOWlibsql-sqlite3/ltmain.sh141'
LOWlibsql-sqlite3/ltmain.sh2941# wrapper executable. Must ONLY be called from within
LOWlibsql-sqlite3/ltmain.sh2961}
LOWlibsql-sqlite3/ltmain.sh3041# following $build/$host combinations (but does no harm for
LOWlibsql-sqlite3/ltmain.sh3161# include <direct.h>
LOWlibsql-sqlite3/ltmain.sh3181#include <string.h>
LOWlibsql-sqlite3/ltmain.sh3201
LOWlibsql-sqlite3/ltmain.sh3221# endif
LOWlibsql-sqlite3/ltmain.sh3241# define FOPEN_WB "wb"
LOWlibsql-sqlite3/ltmain.sh6001 # FIXME: Pedantically, this is the right thing to do, so
LOWlibsql-sqlite3/ltmain.sh7121 test "$len" -lt "$max_cmd_len" || test "$max_cmd_len" -le -1; then
LOWlibsql-sqlite3/ltmain.sh8441# them. This is particularly important on AIX, because we don't
LOWlibsql-sqlite3/magic.txt1# This file contains suggested magic(5) text for the unix file(1)
LOWlibsql-sqlite3/benchmark/benchtest.c1#include "../parse.h"
LOWlibsql-sqlite3/benchmark/anntest.c1#include "../parse.h"
LOWlibsql-sqlite3/test/fuzzcheck.c81#include <stdio.h>
LOWlibsql-sqlite3/test/kvtest.c121#include "sqlite3.h"
LOWlibsql-sqlite3/test/speedtest1.c61#include <ctype.h>
LOWlibsql-sqlite3/test/threadtest3.c41#define opendb(w,x,y,z) (SEL(w), opendb_x(w,x,y,z))
LOWlibsql-sqlite3/test/threadtest3.c81
LOWlibsql-sqlite3/test/wordcount.c61** gcc -I. -DSQLITE_THREADSAFE=0 -DSQLITE_OMIT_LOAD_EXTENSION \
LOWlibsql-sqlite3/test/dbfuzz.c21** the fuzzed database.
LOWlibsql-sqlite3/test/json/json-speed-check.sh1#!/bin/bash
LOWlibsql-sqlite3/ext/misc/fileio.c81#include "sqlite3ext.h"
LOWlibsql-sqlite3/ext/misc/fileio.c101# ifndef chmod
LOWlibsql-sqlite3/ext/misc/base85.c81#include <assert.h>
LOWlibsql-sqlite3/ext/misc/sqlite3_stdio.c21#define WIN32_LEAN_AND_MEAN
LOWlibsql-sqlite3/ext/misc/sqlite3_stdio.c41** or O_TEXT (depending on things like the .mode and the .crlf setting
LOWlibsql-sqlite3/ext/misc/stmt.c81 char **pzErr
LOWlibsql-sqlite3/ext/misc/carray.h41#define CARRAY_INT64 1 /* Data is 64-bit signed integers */
LOWlibsql-sqlite3/ext/misc/zipfile.c41*/
LOWlibsql-sqlite3/ext/misc/zipfile.c61# define UINT16_TYPE unsigned short int
LOWlibsql-sqlite3/ext/misc/vfsstat.c81/*
LOWlibsql-sqlite3/ext/misc/regexp.c81#define RE_OP_ANY 2 /* Match any one character. (Implements ".") */
LOWlibsql-sqlite3/ext/misc/csv.c41*/
LOWlibsql-sqlite3/ext/misc/qpvtab.c141#define QPVTAB_VN 0
LOWlibsql-sqlite3/ext/misc/unionvtab.c161#ifndef ALWAYS
LOWlibsql-sqlite3/ext/misc/sqlite3_stdio.h41void sqlite3_fsetmode(FILE *stream, int mode);
LOWlibsql-sqlite3/ext/misc/base64.c61# define deliberate_fall_through __attribute__((fallthrough));
LOWlibsql-sqlite3/ext/misc/btreeinfo.c61** SELECT name FROM sqlite_btreeinfo
LOWlibsql-sqlite3/ext/misc/normalize.c81#define CC_DOLLAR 4 /* '$' */
LOWlibsql-sqlite3/ext/misc/normalize.c261#define TK_SEMI TK_PUNCT
LOWlibsql-sqlite3/ext/misc/normalize.c281#define TK_ID TK_NAME
LOWlibsql-sqlite3/ext/misc/carray.c61 void *iov_base;
LOWlibsql-sqlite3/ext/misc/shathree.c181# define a11 (p->u.s[6])
LOWlibsql-sqlite3/ext/misc/spellfix.c21# if !defined(NDEBUG) && !defined(SQLITE_DEBUG)
LOWlibsql-sqlite3/ext/consio/console_io.c21#ifndef SHELL_NO_SYSINC
LOWlibsql-sqlite3/ext/consio/console_io.c41# undef WIN32_LEAN_AND_MEAN
LOWlibsql-sqlite3/ext/consio/console_io.c81# define SHELL_INVALID_CONS_MODE 0xFFFF0000
LOWlibsql-sqlite3/ext/consio/console_io.c761# endif
LOWlibsql-sqlite3/ext/async/sqlite3async.h221#endif
907 more matches not shown…
Hallucination Indicators14 hits · 165 pts
SeverityFileLineSnippet
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java462 new org.sqlite.jni.capi.OutputPointer.Int64();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java464 new org.sqlite.jni.capi.OutputPointer.Int64();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java480 new org.sqlite.jni.capi.OutputPointer.Int32();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java482 new org.sqlite.jni.capi.OutputPointer.Int32();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java695 new org.sqlite.jni.capi.OutputPointer.sqlite3_stmt();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java697 new org.sqlite.jni.capi.OutputPointer.Int32();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java809 new org.sqlite.jni.capi.OutputPointer.Int32();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java910 = new org.sqlite.jni.capi.OutputPointer.String();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java912 = new org.sqlite.jni.capi.OutputPointer.String();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java914 = new org.sqlite.jni.capi.OutputPointer.Bool();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java916 = new org.sqlite.jni.capi.OutputPointer.Bool();
CRITICAL…qlite3/ext/jni/src/org/sqlite/jni/wrapper1/Sqlite.java918 = new org.sqlite.jni.capi.OutputPointer.Bool();
CRITICAL…sqlite3/ext/jni/src/org/sqlite/jni/capi/SQLTester.java460 sb.append(org.sqlite.jni.capi.ResultCode.getEntryForInt(rc)).append(' ');
CRITICAL…lite3/ext/jni/src/org/sqlite/jni/tester/SQLTester.java460 sb.append(org.sqlite.jni.capi.ResultCode.getEntryForInt(rc)).append(' ');
Self-Referential Comments20 hits · 60 pts
SeverityFileLineSnippet
MEDIUMlibsql-sqlite3/ltmain.sh899# This function is only a basic sanity check; it will hardly flush out
MEDIUMlibsql-sqlite3/ltmain.sh910# This function implements the same check as func_lalib_p without
MEDIUMlibsql-sqlite3/ltmain.sh933# This function is only a basic sanity check; it will hardly flush out
MEDIUMlibsql-sqlite3/ltmain.sh942# This function is only a basic sanity check; it will hardly flush out
MEDIUMlibsql-sqlite3/ltmain.sh970# This function is only a basic sanity check; it will hardly flush out
MEDIUMlibsql-sqlite3/ltmain.sh1071# Create a libtool object file (analogous to a ".la" file),
MEDIUMlibsql-sqlite3/ltmain.sh4944 # Create the object directory.
MEDIUMlibsql-sqlite3/ltmain.sh7454 # Create the old-style object.
MEDIUMlibsql-sqlite3/ltmain.sh7474 # Create an invalid libtool object if no PIC, so that we don't
MEDIUMlibsql-sqlite3/contrib/bootstrap.fedora.sh23# Create the m4/ directory if it doesn't exist.
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1229# This function is only a basic sanity check; it will hardly flush out
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1240# This function implements the same check as func_lalib_p without
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1263# This function is only a basic sanity check; it will hardly flush out
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1272# This function is only a basic sanity check; it will hardly flush out
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1297# This function is only a basic sanity check; it will hardly flush out
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh1433# Create a libtool object file (analogous to a ".la" file),
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh6028 # Create the object directory.
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh8656 # Create the old-style object.
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh8676 # Create an invalid libtool object if no PIC, so that we don't
MEDIUM.github/workflows/libsql-server-release.yml256 # Create a GitHub Release while uploading all files to it
Decorative Section Separators10 hits · 39 pts
SeverityFileLineSnippet
MEDIUMlibsql-sqlite3/ext/fts3/unicode/CaseFolding.txt30# ================================================================================
MEDIUMlibsql-sqlite3/ext/fts3/unicode/CaseFolding.txt32# ================================================================================
MEDIUMlibsql-sqlite3/ext/fts3/unicode/CaseFolding.txt54# =================================================================
MEDIUMlibsql-sqlite3/ext/fts3/unicode/CaseFolding.txt63# =================================================================
MEDIUMlibsql-server/src/h2c.rs29//! ┌───────────────┐ upgrade:h2c ┌──────────────────┐
MEDIUMlibsql-server/src/h2c.rs30//! │ http::request ├────────────────────────►│ upgrade to http2 │
MEDIUMlibsql-server/src/h2c.rs31//! └─────┬─────────┘ └────────┬─────────┘
MEDIUMlibsql-server/src/h2c.rs37//! │ ┌─────────────────┐ │
MEDIUMlibsql-server/src/h2c.rs38//! └────────────►│call axum router │◄───────────┘
MEDIUMlibsql-server/src/h2c.rs39//! └─────────────────┘
AI Slop Vocabulary10 hits · 30 pts
SeverityFileLineSnippet
MEDIUMlibsql-sqlite3/ltmain.sh210# Sed substitution that helps us do robust quoting. It backslashifies
MEDIUMlibsql-sqlite3/ltmain.sh2726# Sed substitution that helps us do robust quoting. It backslashifies
MEDIUMlibsql-sqlite3/ltmain.sh6538 # This code stresses the "libraries are programs" paradigm to its
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh397# Sed substitution that helps us do robust quoting. It backslashifies
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh3852# Sed substitution that helps us do robust quoting. It backslashifies
MEDIUM…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh7681 # This code stresses the "libraries are programs" paradigm to its
MEDIUMbottomless/src/replicator.rs1172 // it should be more robust and continue looking if the first item does not
MEDIUMlibsql-server/src/schema/scheduler.rs286 // the code more robust when there are spurious wakups that would cause to this
MEDIUMlibsql-server/src/replication/snapshot.rs190 // FIXME(marin): we somehow need to make this code more robust. How to deal with a
MEDIUMvendored/rusqlite/src/lib.rs644 /// likely to be more robust.
Redundant / Tautological Comments4 hits · 6 pts
SeverityFileLineSnippet
LOWlibsql-sqlite3/ltmain.sh1717 # Check if any of the arguments is a wrapper script.
LOWlibsql-sqlite3/ltmain.sh7186 # Loop over the list of objects to be linked.
LOW…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh2593 # Check if any of the arguments is a wrapper script.
LOW…ndled/SQLite3MultipleCiphers/admin/build-aux/ltmain.sh8382 # Loop over the list of objects to be linked.
Unused Imports5 hits · 5 pts
SeverityFileLineSnippet
LOW…i/bundled/SQLite3MultipleCiphers/scripts/amalgamate.py31
LOW…i/bundled/SQLite3MultipleCiphers/scripts/amalgamate.py32
LOW…i/bundled/SQLite3MultipleCiphers/scripts/amalgamate.py33
LOW…i/bundled/SQLite3MultipleCiphers/scripts/amalgamate.py40
LOWlibsql-server/scripts/gen_certs.py11
Verbosity Indicators3 hits · 4 pts
SeverityFileLineSnippet
LOWlibsql-server/src/http/user/dump.rs50 // The stream was closed but we need to check if the dump task failed and forward the
LOWscripts/update-sqlite-bundle.sh30# Step 1: regenerate the Rust bindings.
LOWscripts/update-sqlite-bundle.sh37# Step 2: regenerate the C amalgamation in both bundled locations using the
Excessive Try-Catch Wrapping2 hits · 4 pts
SeverityFileLineSnippet
MEDIUMlibsql-sqlite3/ext/jni/README.md68 System.out.print("Error opening db: "+sqlite3_errmsg(db));
MEDIUMlibsql-sqlite3/ext/jni/README.md70 System.out.print("Error opening db: rc="+rc);
Slop Phrases1 hit · 2 pts
SeverityFileLineSnippet
LOWlibsql-server/src/schema/status.rs156 // don't forget to update that!
Hyper-Verbose Identifiers1 hit · 1 pts
SeverityFileLineSnippet
LOWlibsql-sqlite3/tool/vectoridx_graphviz.py13def neighbour_metadata_offset(block_size, v_type, v_dims):
Deep Nesting1 hit · 1 pts
SeverityFileLineSnippet
LOW…i/bundled/SQLite3MultipleCiphers/scripts/amalgamate.py135