14 - [-] Convert to Typed Racket
15 - [x] build executable (otherwise too-slow)
22 - see timeline ops above
26 - Watch FIFO for lines, then read, timestamp and append [+ upload].
27 Can be part of a "live" mode, along with background polling and
28 incremental printing. Sort of an ii-like IRC experience.
30 - see timeline ops above
31 - see hashtag and channels above
34 - [ ] all - use all known peers
35 - [ ] fast - all except peers known to be slow or unavailable
38 - calls user-configured command to upload user's own timeline file to their server
39 Looks like a better CLI parser than "racket/cmdline": https://docs.racket-lang.org/natural-cli/
40 But it is no longer necessary now that I've figured out how to chain (command-line ..) calls.
47 - [-] parse peer refs from peer timelines
48 - [x] mentions from timeline messages
49 - [x] @<source.nick source.url>
51 - [x] "following" from timeline comments: # following = <nick> <uri>
52 - [ ] Parse User-Agent web access logs.
53 - [ ] Update peer ref file(s)
54 Rough sketch from late 2019:
57 let write file peers =
60 (* Fetch could mean either or both of:
61 * - fetch peer's we-are-twtxt.txt
62 * - fetch peer's twtxt.txt and extract mentioned peer URIs
67 let rec discover peers_old =
69 Set.fold peers_old ~init:peers_old ~f:(fun peers p ->
72 (* TODO: Should p be moved to down set here? *)
76 Set.union peers peers_fetched
79 if Set.empty (Set.diff peers_old peers_all) then
83 let rec loop interval peers_old =
84 let peers_all = discover peers_old in
85 let (peers_up, peers_down) = test peers_all in
86 write "peers-all.txt" peers_all;
87 write "peers-up.txt" peers_up;
88 write "peers-down.txt" peers_down;
90 loop interval peers_all
92 loop (Sys.argv.(1)) (read "peers-all.txt")
96 - [ ] Background polling and incremental timeline updates.
97 We can mark which messages have already been printed and print new ones as
100 - [ ] Use ETag to prevent redundant downloads
101 - [ ] Polling mode/command, where tt periodically polls peer timelines
102 - [ ] nick tiebreaker(s)
103 - [ ] some sort of a hash of URI?
104 - [ ] angry-purple-tiger kind if thingie?
105 - [ ] P2P nick registration?
106 - [ ] Peers vote by claiming to have seen a nick->uri mapping?
107 The inherent race condition would be a feature, since all user name
108 registrations are races.
111 - [ ] download times per peer
112 - [ ] Support redirects
113 - should permanent redirects update the peer ref somehow?
114 - [ ] Support time ranges (i.e. reading the timeline between given time points)
115 - [ ] optional text wrap
117 - [ ] timeline limits
118 - [ ] peer refs set operations (perhaps better done externally?)
119 - [ ] timeline as a result of a query (peer ref set op + filter expressions)
121 - [ ] highlight mentions
122 - [ ] filter on mentions
123 - [ ] highlight hashtags
124 - [ ] filter on hashtags
125 - [ ] hashtags as channels? initial hashtag special?
127 - [ ] console logger colors by level ('error)
128 - [ ] file logger ('debug)
129 - [ ] Suport immutable timelines
130 - store individual messages
132 - something like DBM or SQLite - faster
133 - filesystem - transparent, easily published - probably best
134 - [ ] block(chain/tree) of twtxts
135 - distributed twtxt.db
136 - each twtxt.txt is a ledger
137 - peers can verify states of ledgers
138 - peers can publish known nick->url mappings
139 - peers can vote on nick->url mappings
140 - we could break time periods into blocks
141 - how to handle the facts that many(most?) twtxt are unseen by peers
146 - [x] caching (use cache by default, unless explicitly asked for update)
147 - [x] value --> cache
148 - [x] value <-- cache
150 - [x] Logger sync before exit.
151 - [x] Implement rfc3339->epoch
152 - [x] Remove dependency on rfc3339-old
153 - [x] remove dependency on http-client
154 - [x] Build executable
155 Implies fix of "collection not found" when executing the built executable
156 outside the source directory:
158 collection-path: collection not found
160 in collection directories:
162 /usr/share/racket/collects/racket/private/collect.rkt:11:53: fail
163 /usr/share/racket/collects/setup/getinfo.rkt:17:0: get-info
164 /usr/share/racket/collects/racket/contract/private/arrow-val-first.rkt:555:3
165 /usr/share/racket/collects/racket/cmdline.rkt:191:51
171 - [~] named timelines/peer-sets
172 REASON: That is basically files of peers, which we already support.