

Show HN: My attempt at a decentralised Reddit - flynnbo
https://memesfortheparanoid.com

======
i336_
I've had it open for about 5 minutes.

The root page (/) showed "peers: 2" for a while now, now it says "peers: 1".

I see a list of two files, both just do

    
    
        while(1) {
    
           connecting
           connecting.
           connecting..
           connecting...
    
        }
    

It might be a good idea to have an info page that explains what's going on
(I'm presuming my ability to see files is based on other peoples' browsers
being open?).

Also, I really like the design as it is right now. Don't feel pressured to
change it all that much - keep it HN-esque. :)

A textarea would be cool though. With CTRL+Enter. :P

Oh and an API!

And an authentication system that uses say Google's one-click captcha engine
for passersby and a highly convoluted auth system no spammer would want to put
up with so bots and clients and Real Users(TM) can connect! (Like "please DCC
SEND a base64-challenge-response-encoded public key to this random IRC user on
blahblah private network using this IP address with this one-time
password...")

~~~
flynnbo
I really appreciate the advice. It says connecting until the server has
facilitated a connection between you and a peer if no peers are online it will
say connection for ever. There is an api available.
HTTPS://github.com/flynnbo/hookmeup. Will connect you to other peers. I will
implement the recaptcha to prevent spam. And maybe setup a bot to always be
available. Thanks once again.

~~~
i336_
Aw, cool :D

I'm really interested to see where this goes.

I just fired it back up to have another look, and I thought of a couple more
ideas:

\- If it's not too hard, maintain a live-updated index of how many peers are
available for each file on the file listing page (and extend the API so it
returns this data too). That way I won't be sitting waiting forever _because I
can 't tell the difference between a backend outage and peer unavailability
for a given file_, which is currently the case.

\- While writing the above idea I thought of this: maybe, at least to begin
with, it might be useful to use a "store'n'forward" type model with the
system, where you say "I'm interested in <this> and <this> file", then once
the files download, the site uses desktop notifications to update you. (I
imagine your API works push-style, so API clients would probably behave
similarly to this by design as well.)

\- Categories of some kind might be a good idea at some point. If you do
implement these, I think everyone would appreciate if it worked like IRC's
/list command - a giant "here's the whole thing" dump, somewhere. Nobody
really knows the full list of subreddits, and on Medium.com there's no public
list of categories _at all_.

\- Sometime wayyyy down the track... it would be _epically_ awesome if you
could allow people to have the option to put OTR under their posts. There are
JavaScript implementations, FWIW, but I'm not sure whether it's possible to
form a cryptographically secure AND anonymous link using OTR... if it is, a
lot of people would love it.

\- At the moment when you click a file it opens in a new tab. That means a new
WebSocket connection for each file. It would both be nicer UX and lighter on
the server if you open files in the same window, methinks.

\- I unfortunately haven't seen what happens when you open a file, but if it
doesn't exist yet, having a "6 other peers agree on file content" message in
the corner of the post view would be a cool idea.

[Staring at "connecting...."] Yeah, you definitely need to update the file
list so it shows peer counts for files. :P

Maybe you could add some "last-resort" code to the backend that hands you the
file if there are no other peers, along with a "warning: this file is not
being delivered using a peer" type message (in red :D)?

~~~
flynnbo
Just implemented the total available peer count. Seeding all files now so it
should work. Hit me up in the comments. Of the file. Once it has loaded

~~~
i336_
I just thought to check HN again ([mumbles something about notifications]),
glad I did. I just opened all the files that are there; Readme.txt has now
loaded, and I commented! :D

And I was thinking something like this for the file listing (look to the right
of the filenames):
[http://i.imgur.com/kC2Dzex.png](http://i.imgur.com/kC2Dzex.png)

But you've implemented the general gist of what I meant perfectly. :D

Edit: THE COMMENTS NEED TIMESTAMPS :P

~~~
flynnbo
Once again thanks for all the feedback this really is astonishing. I will
consider implementing that suggestion but i usually conform to the KISS
principle and it would complicate the protocol if i was to add that ability.
Categories is definitely a must have though. I will get started on that now.
You can use this service to notify of responces on HN
[http://hnnotify.com/](http://hnnotify.com/). :)

------
flynnbo
My inspiration for memesfortheparanoid came from the following blog post
[https://medium.com/@ryanxcharles/fix-reddit-with-
bitcoin-7da...](https://medium.com/@ryanxcharles/fix-reddit-with-
bitcoin-7da3f85fb9ba). However my implementation does not involve bitcoin.
Uses Webrtc datachannels to create p2p connections. It uses a merkle-dag
similar to the blockchain to store a log of all data. To submit a post simply
drag and drop a txt file containing a few wise words. It will be replicated
amongst your peers and their peers until it propagates through the entire
network. All data is saved to indexeddb so when you return to the page you
will make the data available to other peers. I only developed in the last
couple of weeks so very buggy and unattractive. Cheers,

Flynnbo.

