LL
← All projectsLightning Labs

LND

Go implementation of a complete Lightning Network node.

BitcoinLightning NetworkNormal
Repository coverage

1238 commits in the local evidence base

Every captured commit receives deterministic security triage and a separate communication-quality score. Security candidates and broader second-pass signals receive full-patch Ollama analysis.

116security candidates168second-pass queue337AI analyses
55commits · 30 days
168commits · 60 days
827commits · 180 days
1227commits · 365 days
Backfill bands
Aug 5 → Feb 6405 seen5 candidatesComplete
Feb 6 → Jun 6665 seen28 candidatesComplete
Jun 6 → Jul 689 seen4 candidatesComplete
Jul 6 → Aug 569 seen0 candidatesComplete
Commit communication

Does the history explain itself?

Message quality measures whether a commit identifies its scope, purpose, rationale, testing, and supporting references. It does not change the security-severity score.

67/100 average clarity
279Strong · 80–100
561Adequate · 60–79
367Thin · 40–59
31Opaque · 0–39
1security candidate with opaque commit messaging
Read the scoring rubric →
Developer activity

Who is changing the project?

Public Git author strings; identities are not independently verified.

DeveloperCommitsCandidatesAnalyzedHigh riskMessage avg.
Olaoluwa Osuntokun1994084374
Elle Mouton2673170067
ziggie4101584064
Erick Cestari26715070
bitromortac46519067
yyforyongyu55313065
saubyk1523070
Oli724057
Suheb323075
elnosh322071
George Tsagkarelis32114066
Gijs van Dam2614071
Analysis record

Published AI watches

Last scanned 9 minutes ago

Moderate 63 AI analysisMessage 58 · Thin
LL Lightning LabsLND BitcoinLightning Network

Merge pull request #11024 from ziggie1984/invoices-update-validation

This commit tightens how LND processes invoice payments, especially for newer multi-path (MPP) and AMP invoices, keysend payments, and replayed payments. It adds checks that ensure the right payment preimage is used for each invoice type a…

Preimage validation added for AMP and regular invoice replaysAMP invoices forced into MPP update path, preventing legacy-path processingLegacy settlement now fails when invoice-level preimage is missing
61f3b5a7by ziggieXXX+482−114 files
No security note in commit
Moderate 59 AI analysisMessage 35 · Opaque
LL Lightning LabsLND BitcoinLightning Network

invoices: refine update handling

This commit tightens how LND handles invoice payment updates, especially for newer 'AMP' invoices and old-style 'keysend' payments. It adds checks so that the wrong kind of payment cannot be processed against the wrong kind of invoice, and…

Added preimage/hash mismatch checks for both regular and AMP invoice replaysAMP records now require an MPP payload, preventing AMP processing on the legacy pathLegacy path now rejects AMP invoices and invoices missing invoice-level preimages
6be6350eby ziggie+476−113 files
No security note in commit
Informational 15 AI analysisMessage 57 · Thin
LL Lightning LabsLND BitcoinLightning Network

docs: update 0.21.2 release notes

This commit only updates the release notes document for version 0.21.2. It adds a bullet point describing a previously merged code change about invoice handling and adds a contributor name to the credits list. No actual code was changed, s…

758bbb8eby ziggie+6−01 file
No security note in commit
Informational 15 AI analysisMessage 57 · Thin
LL Lightning LabsLND BitcoinLightning Network

docs: move gossip bounds note to v0.21.2

This commit only moves an existing release-note entry from one version's notes (v0.22.0) to another (v0.21.2). It does not change any code, build files, configuration, or tests. The change is purely editorial documentation bookkeeping.

83e7eb8cby ziggie+11−112 files
No security note in commit
High 72 AI analysisMessage 68 · Adequate
LL Lightning LabsLND BitcoinLightning Network

discovery: bound channel range reply buffering

This change fixes a way a malicious or buggy peer could make an LND node use an unpredictable amount of memory while syncing the Lightning channel graph. Before the fix, the node only limited the size of one compressed reply message, but a…

Resource exhaustion / unbounded memory growth in gossip syncRemote peer can influence memory allocation via ReplyChannelRange streamMissing aggregate limit on decoded working set
ceff94faby Olaoluwa Osuntokun+335−153 files
Vendor flagged security relevance
Low 33 AI analysisMessage 47 · Thin
LL Lightning LabsLND BitcoinLightning Network

docs: update release notes

This commit updates the release notes for LND 0.21.2 to describe a fix for a bug in the HTLC interceptor RPC. The bug caused LND to fail to forward payments in blinded routes when the next hop was identified by node ID instead of channel I…

Blinded route forwarding failure could disrupt payment routing or be used to probe path structure.Sentinel value change in RPC API could cause client misclassification of forwards if not handled.Release notes describe the change as a fix for a forwarding issue, not as a security vulnerability.
f42b4298by bitromortac+20−01 file
No security note in commit
Informational 14 AI analysisMessage 83 · Strong
LL Lightning LabsLND BitcoinLightning Network

itest: cover blinded route next_node_id forwarding

This commit only adds new integration tests for an existing feature in LND: forwarding blinded payments where the next hop is identified by node ID rather than channel ID. It does not change production code, fix a bug, or introduce any new…

da6a40c0by bitromortac+432−02 files
No security note in commit
Low 25 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

witness beacon: report node-ID next hop to the on-chain HTLC interceptor

This change fixes a reporting gap in LND's 'witness beacon,' a component that watches on-chain transactions and tells the HTLC interceptor where a payment should go next. Previously, when the next hop was identified by a node ID rather tha…

Missing security-critical metadata in on-chain interception pathBehavioral parity between on-chain and off-chain HTLC interceptionPotential misclassification of node-ID forwards as final receives
9c4b8bfeby bitromortac+59−52 files
No security note in commit
Moderate 59 AI analysisMessage 81 · Strong
LL Lightning LabsLND BitcoinLightning Network

htlcswitch: forward node-ID blinded hops via non-strict forwarding

This commit fixes a bug in LND's payment forwarding for 'blinded routes'—a privacy feature in the Lightning Network. Previously, if the next hop was identified by node ID rather than a specific channel ID, the payment could not be forwarde…

Fixes a functional forwarding failure for blinded-route payments using node-ID next hops (issue #10937).Prevents private channel SCID leakage in failure messages for node-ID blinded hops by returning FailUnknownNextPeer instead of a channel_update.Adds circular-route filtering for node-ID next hops before non-strict forwarding selection.
dbc57040by bitromortac+334−416 files
No security note in commit
Informational 19 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

htlcswitch+lnrpc: report node-ID next hop to the off-chain HTLC interceptor

This change improves how the Lightning Network Daemon (LND) reports forwarding details to external plugins that inspect HTLCs (payment packets). For a new type of blinded route where the next hop is identified by node ID rather than a spec…

Information-correctness fix for HTLC interceptor APIPrevents misclassification of node-ID forwards as exit hopsAdds explicit sentinel to disambiguate zero SCID semantics
32373b76by bitromortac+29−13 files
No security note in commit
Low 25 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

htlcswitch: classify a node-ID forward as a forward event

This commit fixes a bookkeeping bug in LND's HTLC event stream. When a payment is forwarded to a 'blinded' next hop identified only by a node public key (not a channel ID), and it fails before the switch picks an outgoing channel, the even…

Event misclassification in HTLC event stream (forward reported as receive)Blinded/node-ID forwarding path introduced prior to this fixFailure and resolution packets dropped next-hop metadata before fix
a4844ef5by bitromortac+149−04 files
No security note in commit
Low 29 AI analysisMessage 68 · Adequate
LL Lightning LabsLND BitcoinLightning Network

htlcswitch/hop: decode next_node_id blinded hops

This commit adds support in LND for a different way of identifying the next hop in a private ('blinded') Lightning payment route. Previously LND expected the next hop to be identified by a channel ID; now it also accepts the next node's pu…

New validation enforces BOLT 4 mutual exclusivity of short_channel_id and next_node_id in blinded route dataPreviously ambiguous or unhandled next_node_id forwarding case now explicitly decodedNo memory-safety, cryptographic, or authorization changes observed
4fd4289aby bitromortac+471−86 files
No security note in commit
Moderate 60 AI analysisMessage 78 · Adequate
LL Lightning LabsLND BitcoinLightning Network

lnwire: cap decoded short channel IDs

This commit tightens a safety limit in LND's Lightning wire protocol parser. Previously, a compressed network message could decompress into an unbounded number of short channel IDs, potentially consuming far more memory than the wire messa…

Resource-limit bypass: compressed-input bound did not bound decoded outputMemory-exhaustion risk from zlib decompression of peer-supplied dataTruncated/corrupt zlib streams previously accepted as valid partial results
d1622919by Olaoluwa Osuntokun+271−502 files
No security note in commit
Informational 18 AI analysisMessage 85 · Strong
LL Lightning LabsLND BitcoinLightning Network

lnrpc/routerrpc: add outgoing_node_id to HTLC intercept request

This commit only updates the API definition and auto-generated code for LND's HTLC interceptor. It adds a new optional field, outgoing_requested_node_id, and documents that when a blinded route uses a node ID instead of a channel ID, the e…

No runtime logic changed; only protobuf schema and generated stubsNew field is explicitly documented as unpopulated until later commitsSentinel value (MaxUint64) introduced to prevent misclassification of final receive vs node-addressed forward
14640a50by bitromortac+48−73 files
No security note in commit
Informational 18 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

multi: represent the blinded forwarding next hop as an fn.Either

This commit is a behind-the-scenes code cleanup in the LND Lightning node. It changes how the 'next hop' for forwarding payments is stored internally so that, in the future, blinded routes can identify the next hop by a node's public key i…

Refactor of core HTLC forwarding data structure (ForwardingInfo.NextHop)Preparation for blinded route next-hop identification by node public keyEncapsulation of Either type behind IsExit() and NextHopChannel() to centralize exit-hop detection
d28a7176by bitromortac+83−2612 files
No security note in commit
Low 44 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

htlcswitch: key the aux traffic shaper on the evaluated channel

This commit fixes a routing bug in LND's Lightning payment forwarding. When a payment could take any of several parallel channels to the same next peer, the node was accidentally asking an optional 'auxiliary traffic shaper' about the chan…

Logic error: wrong channel identifier used for auxiliary policy/bandwidth checkPotential information disclosure: real SCID could leak if passed to shaper-driven wire messages; commit explicitly prevents thisParallel-channel forwarding correctness issue
b1667800by bitromortac+133−12 files
No security note in commit
Informational 15 AI analysisMessage 68 · Adequate
LL Lightning LabsLND BitcoinLightning Network

github: bump gateway code-review to v0.6.0

This commit updates a GitHub Actions workflow that runs an optional code-review bot called 'gateway'. It only changes two pinned version numbers (SHA hashes) for the bot's action and its runtime, moving from v0.5.0 to v0.6.0. There is no c…

17a4d42fby Suheb+4−41 file
No security note in commit
Moderate 58 AI analysisMessage 68 · Adequate
LL Lightning LabsLND BitcoinLightning Network

channeldb: recover missing db version

This patch fixes a database migration bug in LND's channel database. Some databases were created without recording their schema version number, which could cause future mandatory upgrades to be skipped. The fix detects that missing version…

Database schema version key can be absent due to an init-ordering regressionMissing version key previously caused migration selection to treat DB as latest, potentially skipping mandatory migrationsFix recovers baseline from last mandatory version before the regression (33)
68264c70by Elle Mouton+176−33 files
Vendor flagged security relevance
Informational 22 AI analysisMessage 73 · Adequate
LL Lightning LabsLND BitcoinLightning Network

channeldb: make waiting proof migration repeatable

This commit fixes a database migration in LND so it can safely run twice. Previously, if a certain recovery process re-ran migration 35 on a database that already had newer-format 'waiting proof' records, the migration would likely fail or…

Database migration idempotency/robustness fixPotential data corruption or node startup failure if migration re-run against mixed-format bucketNo input validation of attacker-controlled data; issue is local/state-recovery only
3aff61aeby Elle Mouton+93−02 files
No security note in commit
Moderate 54 AI analysisMessage 76 · Adequate
LL Lightning LabsLND BitcoinLightning Network

channeldb: preserve db version during init

This commit fixes a database initialization bug in LND's channel database. Previously, creating an empty metadata bucket during setup could trick the code into thinking an old or partially-created database was already fully up-to-date, pot…

Database version detection logic flawPotential migration skip due to incorrect initialized-state detectionNew explicit error for missing DB version key
619913bfby Elle Mouton+111−104 files
No security note in commit
Repository ledger

Explore captured commits

Expand any commit for its author, full message, clarity score, changed files, triage signals, analysis, and source link.

Lower-prioritypaymentsdb: use non-terminal payment query for recoveryby yyforyongyu · 96cbd4a7 · Apr 7, 2026 · 1 fileMessage 83 · StrongLow 30Details
Commit message · yyforyongyu

paymentsdb: use non-terminal payment query for recovery

The new FetchNonTerminalPayments query is available, but
FetchInFlightPayments still uses the old unresolved-attempt scan until
this commit.

Use the inflight recovery regression tests as evidence. They now pass
on both KV and SQL once the payment store is wired up to use the new
query.

Fix this by switching FetchInFlightPayments to the non-terminal
payment query and batch loading only the related attempt and route
data for those payment IDs.

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Low 30/100

This commit fixes how LND's SQL payment store finds payments that are still in progress during startup recovery. Previously it scanned individual payment attempts that were still unresolved, which could miss or mishandle payments. Now it queries payments directly by their non-terminal status and loads only the related attempt data. The change is framed by the developer as fixing a regression in recovery behavior, with tests now passing on both database backends.

Lower-prioritysqldb/sqlc: add non-terminal payment queryby yyforyongyu · 4c163acf · Apr 7, 2026 · 5 filesMessage 78 · AdequateInformational 12Details
Commit message · yyforyongyu

sqldb/sqlc: add non-terminal payment query

FetchInFlightPayments needs a dedicated SQL query that can return
non-terminal payments without relying on the unresolved-attempt scan.
The first version of that query fixed correctness, but the follow-up
selector measurements showed a UNION-based shape was materially
faster while returning the same payment set.

Use the inflight regression tests as evidence. The tests still fail on
SQL before the Go payment store is wired up, but this commit adds the
final SQL surface the later wiring commit depends on.

Add FetchNonTerminalPayments to the SQL query set, regenerate the sqlc
bindings, add the PaymentAndIntent adapters for the new row type, and
use the UNION-based candidate selection so the final query shape lands
in one commit.

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Informational 12/100

This commit adds a new database query to the Lightning Network Daemon (LND) for finding payments that haven't finished yet. It is a performance and correctness improvement to how the node tracks in-flight payments. There is no indication it fixes a security vulnerability or introduces a new attack path.

Lower-prioritypaymentsdb: add AMP hash regression testby yyforyongyu · e8c58fc0 · Apr 7, 2026 · 1 fileMessage 90 · StrongLow 41Details
Commit message · yyforyongyu

paymentsdb: add AMP hash regression test

SQL writes store the payment identifier in payment_hash for each
attempt. That is wrong for AMP payments, because the payment
identifier is the SetID while each shard carries its own HTLC hash.

Add TestRegisterAttemptPreservesAttemptHash as evidence. It passes on
KV and fails on SQL before the fix because SQL reads the attempt hash
back as the payment identifier.

90/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Low 41/100

This commit only adds a new regression test for the Lightning Network Daemon (LND) payments database. The test checks that for AMP (Atomic Multi-Path) payments, each individual payment attempt keeps its own unique hash rather than being overwritten by the overall payment identifier. The commit message says the test fails on the SQL database backend before a separate fix, but the actual code fix is not included in this commit. So by itself, this change does not fix anything; it only provides a test that demonstrates the bug.

Lower-prioritypaymentsdb: add inflight recovery regression testsby yyforyongyu · 5d9756f8 · Apr 7, 2026 · 1 fileMessage 83 · StrongLow 37Details
Commit message · yyforyongyu

paymentsdb: add inflight recovery regression tests

SQL FetchInFlightPayments only returns payments with an unresolved
attempt row. KV returns every non-terminal payment, including
retryable payments with only failed attempts and payments that have
been initialized but have not registered any HTLCs yet.

Add TestFetchInFlightPaymentsIncludesRetryablePayments and
TestFetchInFlightPaymentsIncludesInitiatedPayments as evidence. Both
tests pass on KV and fail on SQL before the fix.

83/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Why it was queued
fuzzing or regression evidence
AI analysis · Low 37/100

This commit only adds new regression tests to LND's payment database. The tests document that the SQL database backend previously failed to return certain kinds of non-finished (retryable or just-started) payments when asked for in-flight payments, while the older KV backend returned them correctly. The commit itself does not contain the actual fix; it only adds tests that would have failed before the fix. The practical risk is that recovery or routing logic relying on FetchInFlightPayments could miss payments it should retry or monitor, but no direct funds-loss vulnerability is shown in the diff.

Lower-prioritypaymentsdb: preserve AMP attempt hashes in sql storeby yyforyongyu · 53eea4d0 · Apr 7, 2026 · 1 fileMessage 95 · StrongTriage 0Details
Commit message · yyforyongyu

paymentsdb: preserve AMP attempt hashes in sql store

Live SQL writes stored the payment identifier in payment_hash for
each attempt. That works for legacy payments, but it breaks AMP
because the payment identifier is the SetID while each shard carries
its own HTLC hash.

Use TestRegisterAttemptPreservesAttemptHash as evidence. The test now
passes on both KV and SQL.

Fix this by persisting attempt.Hash when it is present and only
falling back to the payment identifier when the attempt hash is nil.
That restores KV parity for AMP attempt reloads.

95/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Mentions testing or verification
Lower-prioritychainreg: accommodate buried taproot deployment in Bitcoin Core v31by Matthew Zipkin · f8314761 · Apr 6, 2026 · 1 fileMessage 81 · StrongTriage 0Details
Commit message · Matthew Zipkin

chainreg: accommodate buried taproot deployment in Bitcoin Core v31

Removes "taproot" from deployments:
https://github.com/bitcoin/bitcoin/pull/26201

Adds "script_flags" field to RPC getdeploymentinfo:
https://github.com/bitcoin/bitcoin/pull/32998

81/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Links an issue, advisory, or supporting reference
Lower-prioritydocs: add release note for cursor-based invoice paginationby ziggie · 85c8e955 · Apr 1, 2026 · 1 fileMessage 62 · AdequateTriage 0Details
Commit message · ziggie

docs: add release note for cursor-based invoice pagination

62/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Uses a recognizable type or scope! No meaningful explanatory body
Why it was queued
documentation-only discount
Lower-priorityinvoices+sqldb/sqlc: replace offset-based pagination with cursor-basedby ziggie · e02f77ec · Apr 1, 2026 · 4 filesMessage 85 · StrongTriage 0Details
Commit message · ziggie

invoices+sqldb/sqlc: replace offset-based pagination with cursor-based

The invoice filter queries (FetchPendingInvoices,
FilterInvoicesBySettleIndex, FilterInvoicesByAddIndex,
FilterInvoicesForward, FilterInvoicesReverse) all used LIMIT+OFFSET for
internal pagination. This causes SQLite to build an ephemeral temp
B-tree for every page to implement the OFFSET skip, making each
successive page O(offset+limit). On nodes with large invoice histories
this compounds into a significant CPU cost — profiling showed
FilterInvoicesReverse consuming 53% of total CPU, with _sqlite3BtreeInsert
and _balance_nonroot (2.4s combined) appearing inside the SELECT due to
the temp B-tree being built and rebalanced to skip rows.

Replace the OFFSET loop (queryWithLimit) with cursor-based pagination
across all four callers in sql_store.go:

- FetchPendingInvoices: add id_cursor param, advance cursor to
last_id + 1 each page.
- InvoicesSettledSince: add id_cursor param alongside the existing
settle_index lower bound, advance cursor to last_id + 1 each page.
- InvoicesAddedSince: cursor starts at idx+1, advances to last_id+1.
- QueryInvoices: forward cursor starts at IndexOffset+1 and advances
by +1; reverse cursor starts at IndexOffset-1 (or MaxInt64) and
advances by -1. Inclusive SQL bounds (>= / <=) are preserved so
query semantics and all existing callers are unchanged.

The queryWithLimit helper is removed as it has no remaining callers.

Each page now performs a single PK seek + forward scan of exactly
page_size rows with no temp sort structure, matching the cursor-based
pattern already used by the payments filter queries.

85/100 · StrongMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Lower-prioritysqldb/v2: limit MigrationExecutor interfaceby Viktor Torstensson · 1b3bea56 · Mar 31, 2026 · 5 filesMessage 90 · StrongTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: limit MigrationExecutor interface

This commit limits the MigrationExecutor interface due to the following
reasoning:

1. SkipMigrations() and DefaultTarget() should not be on the interface
Both are only used by ApplyAllMigrations, which immediately passes the
results back into the same executor. They are internal implementation
details and should be folded into ExecuteMigrations itself.

2. SetSchemaVersion and GetSchemaVersion are test-only but on the
production interface Every caller of these in sqldb/v2 is in test files.
The SetSchemaVersion comment even says "USE WITH CAUTION" — dangerous
test utilities should not be on an interface that every real consumer
must implement. They should be accessible on the concrete types only and
used directly in tests without going through the interface.

3. ExecuteMigrations should not take a MigrationTarget parameter for the
normal path On the normal startup path, callers just do
executor.ExecuteMigrations(executor.DefaultTarget(), stream) — asking
the executor for its default and handing it straight back. The method
should run to latest by default; a version override for tests can live
on the concrete type instead.

90/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode✓ Mentions testing or verification
Lower-prioritysqldb/v2: ensure SqliteConfig.MaxConnections is usedby Viktor Torstensson · 58f757a8 · Mar 31, 2026 · 1 fileMessage 50 · ThinTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: ensure SqliteConfig.MaxConnections is used

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Lower-prioritysqldb/v2: rename the `postgresErrMsgs` listby Viktor Torstensson · 4219e5ae · Mar 31, 2026 · 1 fileMessage 60 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: rename the `postgresErrMsgs` list

Rename the `postgresErrMsgs` list to `postgresRetriableErrMsgs`, in
order to clarify its usage.

60/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body
Lower-prioritysqldb/v2: rename `ErrRetriesExceeded` errorby Viktor Torstensson · a726dbd0 · Mar 31, 2026 · 3 filesMessage 60 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: rename `ErrRetriesExceeded` error

rename the `ErrRetriesExceeded` error to `ErrTxRetriesExceeded`.

60/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides an explanatory body
Lower-prioritysqldb/v2: use `defaultMaxIdleConns` in SqliteStoreby Viktor Torstensson · 0c8f5211 · Mar 31, 2026 · 1 fileMessage 73 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: use `defaultMaxIdleConns` in SqliteStore

The code previously used `defaultMaxOpenConns` for both the maximum
number of open connections and the maximum number of idle connections in
the `SqliteStore`.

This commit updates the code to use `defaultMaxIdleConns` for the
maximum number of idle connections.

73/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: rename MigrationConfig to MigrationDescriptorby Viktor Torstensson · 9946d521 · Mar 31, 2026 · 1 fileMessage 50 · ThinTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: rename MigrationConfig to MigrationDescriptor

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Lower-prioritysqldb/v2: add MaxIdleConnections & ConnMaxLifetime sqlite optsby Viktor Torstensson · cff8836e · Mar 31, 2026 · 2 filesMessage 50 · ThinTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: add MaxIdleConnections & ConnMaxLifetime sqlite opts

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Lower-prioritysqldb/v2: clarify config options docsby Viktor Torstensson · 1819b986 · Mar 31, 2026 · 1 fileMessage 68 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: clarify config options docs

The documentation for the `SqliteConfig.MaxConnections`,
`PostgresConfig.MaxOpenConnections` and
`PostgresConfig.MaxIdleConnections` previously stated that an unlimited
number was used when the value was set to 0. This is not the case
however, as setting the value to 0 will result in the default values
being used.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: rename test db helper filesby Viktor Torstensson · afc1a675 · Mar 31, 2026 · 2 filesMessage 78 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: rename test db helper files

Previously, the test db helper files were suffixed with "_test", which
would indicate that the files specifically contained tests.
However, these files actually contain helper functions to be used
in tests, and are not tests themselves. To better reflect their
purpose, the files have been renamed to instead be prefixed with
"test_".

78/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Mentions testing or verification
Lower-prioritysqldb/v2: sync features with tapd's sqldb packageby Viktor Torstensson · 13d0cf11 · Mar 31, 2026 · 10 filesMessage 80 · StrongTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: sync features with tapd's sqldb package

In order to make it possible to replace `tapd`'s internal `sqldb`
package with the new generic `sqldb/v2` package, we need to make sure
that all features and functionality that currently exist in the `tapd`
package are also present in the new `sqldb/v2` package.

This commit adds such additional missing features to the `sqldb/v2`
package.

80/100 · StrongMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context✓ Explains rationale or failure mode
Lower-prioritysqldb/v2: clarify no_sqlite `SqliteStore` intentby Viktor Torstensson · 07fdd0f4 · Mar 31, 2026 · 1 fileMessage 68 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: clarify no_sqlite `SqliteStore` intent

The docs of the `SqliteStore` for no sqlite build environments
previously didn't clarify that the actual `SqliteStore` implementation
under such build tag environments, didn't actually implement a real
sqlite store. This commit clarifies that in the docs.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: move Sqlite test helpers to separate fileby Viktor Torstensson · 422dd5d2 · Mar 31, 2026 · 2 filesMessage 60 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: move Sqlite test helpers to separate file

60/100 · AdequateMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component✓ Mentions testing or verification! No meaningful explanatory body
Lower-prioritysqldb/v2: set predictable NewTestPgFixture container nameby Viktor Torstensson · 12d97cc4 · Mar 31, 2026 · 1 fileMessage 50 · ThinTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: set predictable NewTestPgFixture container name

50/100 · ThinMessage clarity
✓ Specific, descriptive subject✓ Names a concrete action or component! No meaningful explanatory body
Lower-prioritysqldb/v2: introduce sqldb/v2 `BaseDB`by Viktor Torstensson · 472deadc · Mar 31, 2026 · 7 filesMessage 68 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: introduce sqldb/v2 `BaseDB`

This commit updates the definition of the `BaseDB` struct to decouple
it from lnd`s `sqlc` package. We also introduce new fields to the struct
to make it possible to track the database type used at runtime.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: Use `MigrationStream` for migrationsby Viktor Torstensson · b0c7c570 · Mar 31, 2026 · 12 filesMessage 68 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: Use `MigrationStream` for migrations

This commit updates the `sqldb/v2` package to utilize the new
`MigrationStream` type for executing migrations, instead of passing
`[]MigrationConfig`'s directly.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: move all non lnd-specific v1 code to v2by Viktor Torstensson · d7a5127c · Mar 31, 2026 · 16 filesMessage 68 · AdequateTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: move all non lnd-specific v1 code to v2

This commit moves all non lnd-specific code of sqldb/v1 to the new
sqldb/v2 module.

Note however, that without additional changes, this package still needs
to reference lnd, as references to the lnd `sqlc` package is required
without further changes. Those changes will be introduced in the
upcoming commits, to fully decouple the new sqldb/v2 module from lnd.

68/100 · AdequateMessage clarity
✓ Descriptive subject✓ Names a concrete action or component✓ Provides detailed explanatory context
Lower-prioritysqldb/v2: introduce `MigrationStream`by Viktor Torstensson · 1c833c5c · Mar 31, 2026 · 3 filesMessage 58 · ThinTriage 0Details
Commit message · Viktor Torstensson

sqldb/v2: introduce `MigrationStream`

This commit introduces a new struct named `MigrationStream`, which
defines a structure for migrations SQL migrations.

The `MigrationStream` struct contains the SQL migrations which will be
applied, as well as corresponding post-migration code migrations which
will be executed afterwards. The struct also contains fields which
define how the execution of the migrations are tracked.

Importantly, it is also possible to define multiple different
`MigrationStream`s which are executed, to for example define one `prod`
and one `dev` migration stream.

58/100 · ThinMessage clarity
✓ Descriptive subject✓ Provides detailed explanatory context