From rusty at rustcorp.com.au Mon Dec 4 23:30:05 2017 From: rusty at rustcorp.com.au (Rusty Russell) Date: Tue, 05 Dec 2017 10:00:05 +1030 Subject: [Lightning-dev] Section 7 Query: Timestamps & Pruning In-Reply-To: References: Message-ID: <87vahmvzpe.fsf@rustcorp.com.au> Shannon Appelcline writes: > Section 7 says "nodes MAY prune channels should the timestamp of the > latest `channel_update` be older than 2 weeks (1209600 seconds)" > > Yet timestamps are only required to be sequential, not an actual > timestamp ("The creating node MUST set `timestamp` to be greater than > that for any previous `node_announcement` it has created. It MAY base it > on a UNIX timestamp.", so there's no way to know the age of a timestamp, > at least not by looking at the timestamp. (lightning-dev CC'd) Indeed. The original timestamp field was left undefined, but this addition implies it has to be epoch time. I prefer it to say "MAY prune channels which have not had a new `channel_update` for 2 weeks or more", but that implies that implementations must keep their own internal timestamp of when they see the update. But we should fix it one way or another; I've opened a bug: https://github.com/lightningnetwork/lightning-rfc/issues/302 Thanks, Rusty.