Otoh, I can't see your replies in gossip. So...

Otherwise I'd be posting my adventures in trying to install notedeck here...

(Cargo gets egui-winit, which wants a newer rustc (!!) than the Ubuntu install, so now I'm trying to use rustup. Which doesn't do anything until you read the docs...)

Reply to this note

Please Login to reply.

Discussion

yeah i think rustup is what should be used.

notedeck is powered by a custom C database I wrote built on lmdb: https://github.com/damus-io/nostrdb all notes are stored as aligned structs and the entire db is mmap’d in memory. So db query results are just pointers into virtual memory. its super fast!

Reviewing. You should have used tdb, of course, but as Tridge said, you don't need an excuse to rewrite something!

never heard of tdb. Docs are sparse on nostrdb, i need to work on that 😅

Yeah, it's a well-kept secret unfortunately.

Rough skimming code review:

1. bool is your friend, int is for old people :(

2. You should use ccan/ directly not in pieces: easier to update.

3. Your cursor API makes me cry, can I rewrite it? It's going to hurt somebody.

4. Do you want neatening pull requests?

sure, happy to have any help

Let's see what I can do after lunch then. Fun!

👀

Simple rework PR up. I also want to update your BOLT11 parser to the latest (it's buggy).

I need to think harder about your cursor API: my instinct is to split it into two types, one for reading, one for writing. But you do a lot of lookahead in your parsing, so the classic "mark cursor invalid if we hit an error" pattern doesn't fit. Hmm....