• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

lightningnetwork / lnd / 12343072627

15 Dec 2024 11:09PM UTC coverage: 57.504% (-1.1%) from 58.636%
12343072627

Pull #9315

github

yyforyongyu
contractcourt: offer outgoing htlc one block earlier before its expiry

We need to offer the outgoing htlc one block earlier to make sure when
the expiry height hits, the sweeper will not miss sweeping it in the
same block. This also means the outgoing contest resolver now only does
one thing - watch for preimage spend till height expiry-1, which can
easily be moved into the timeout resolver instead in the future.
Pull Request #9315: Implement `blockbeat`

1445 of 2007 new or added lines in 26 files covered. (72.0%)

19246 existing lines in 249 files now uncovered.

102342 of 177975 relevant lines covered (57.5%)

24772.24 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

66.67
/chainio/log.go
1
package chainio
2

3
import (
4
        "github.com/btcsuite/btclog/v2"
5
        "github.com/lightningnetwork/lnd/build"
6
)
7

8
// Subsystem defines the logging code for this subsystem.
9
const Subsystem = "CHIO"
10

11
// clog is a logger that is initialized with no output filters. This means the
12
// package will not perform any logging by default until the caller requests
13
// it.
14
var clog btclog.Logger
15

16
// The default amount of logging is none.
17
func init() {
17✔
18
        UseLogger(build.NewSubLogger(Subsystem, nil))
17✔
19
}
17✔
20

21
// DisableLog disables all library log output. Logging output is disabled by
22
// default until UseLogger is called.
NEW
23
func DisableLog() {
×
NEW
24
        UseLogger(btclog.Disabled)
×
NEW
25
}
×
26

27
// UseLogger uses a specified Logger to output package logging info. This
28
// should be used in preference to SetLogWriter if the caller is also using
29
// btclog.
30
func UseLogger(logger btclog.Logger) {
17✔
31
        clog = logger
17✔
32
}
17✔
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc