News for hackers. Stuff that matters.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by metalmanac on Wednesday April 26, 2017 @11:17AM (#14203661)
You should have put up a demo site where users can try out the comment engine. Requiring the installation on a user's laptop/desktop is just too much friction, not to mention mobile users who don't have the luxury of running go scripts.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:08PM (#14205449)
Whoa, this blew up! Here's a working demo that I just hacked together: https://adtac.github.io/commento/comment.html

Edit: sorry, I had to purge the comment list because of an update. From now on, your comment will only be alive for 30 minutes. It'll be deleted after that. This is, of course, only for the demo.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by gizzlon on Wednesday April 26, 2017 @02:56PM (#14205897)
Nice, that demo loaded pretty fast even with a lot of comments :)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @03:12PM (#14206035)
And I'm only using now.sh's free tier for the backend.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by reddit_clone on Wednesday April 26, 2017 @05:28PM (#14207162)
I was going to comment on the slightly laggy edit box. This might explain that?

I am on FireFox 53.0 on a decent Windows 10 laptop.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Thursday April 27, 2017 @12:06AM (#14209100)
That is because there are over 7000 comments right now. Clearing it. Try again, it should be snappy.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by kerneldeveloper on Wednesday April 26, 2017 @08:39PM (#14208273)
How do I get notified when someone else replies my comment?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by grzm on Wednesday April 26, 2017 @09:01PM (#14208372)
You can use 'dangrossman's hnreplies: http://www.hnreplies.com
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by j_s on Wednesday April 26, 2017 @02:52PM (#14205865)
Related discussion: Replacing Disqus with GitHub Comments | https://news.ycombinator.com/item?id=14170041

Recommended alternatives to Commento (Golang):

· https://posativ.org/isso/ (Python)

· https://github.com/jimpick/lambda-comments (Node.js, AWS)

Github-based alternatives:

· https://staticman.net for Github comments

· Github Issues for comments ( http://donw.io/post/github-comments/ )

> https://github.com/shurcooL/issuesapp

> http://ebarnouflant.com/posts/4-turn-your-github-issues-into...

· Github Wiki for blogging: https://github.com/stickfigure/blog/wiki/GitHub%27s-wiki-mak...

· remove comments and use Pull Requests and Issues for substantive discussion

Other options:

· Reddit, Facebook, Discourse for comments

· Privacy via Disqus comments on demand when pressing a button

· Google Wave via Sandstorm

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by stevekemp on Thursday April 27, 2017 @04:24AM (#14210017)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by tyingq on Wednesday April 26, 2017 @09:50PM (#14208591)
Firebase is probably an interesting option as it would likely fit in the free tier, and JavaScript friendly, so easy on-page integration.

And you get Google, Twitter, GitHub, etc sign on for free.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by stewsnooze on Wednesday April 26, 2017 @03:33PM (#14206218)
The Solid framework, supported by Tim Berners-Lee, is looking for an app like this to be built to add to its list of Wishlist apps.

https://github.com/solid/solid-apps#general-wishlist

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by na85 on Wednesday April 26, 2017 @11:16PM (#14208932)
>supported by Tim Berners-Lee

An endorsement from Mr Berners-Lee means little, having caved on the DRM issue.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by mzzter on Wednesday April 26, 2017 @11:39AM (#14203922)
Half the value of Disqus is that it hosts the server API for you. Any viable alternative to disqus or other commenting engine needs to provide hosting too. Otherwise, it's not useful out of the box for static websites and blogs using shared hosting. The challenge is integrating comments without the ability to control the dynamic server backend.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by jgaa on Wednesday April 26, 2017 @12:27PM (#14204477)
The other half value of Disqus is to provide comments to static sites. Back in the days, most sites used dynamic content, and had comments as part of the CMS system they used. Today, lots of sites have no back-end database, and unfortunately, lots of such sites use Disqus simply for convenience. Convenience that hurt the sites, and their visitors (slow load time, unacceptable tracking & spying). Any alternative should be welcomed.

If the sites that use Disqus today were willing to pay for an alternative, I would personally offer hosting of such, with fast load times and no tracking. However, I don't believe such willingness exists, and people are getting conditioned to accept sluggish load times and tracking. Too bad. Self hosted Open Source solutions are the second best alternative - management gets the illusion that the thing is free, and you actually get fast load times and no tracking.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by Karunamon on Wednesday April 26, 2017 @02:40PM (#14205759)
For context, the "load times" we're talking about in the context of Disqus, at least the ones given in the articles I've read, is about 3 seconds. What's more, the javascript is below the fold, so you've already read the site content before seeing the unloaded comment section anyways.

I find it very hard to get worked up about 200k and 3 seconds of nonblocking load.

The tracking is of more immediate concern, but you also have to make a choice as a site owner:

1. Host your own comments. Nobody does this anymore because nobody likes registering for every site out there. You can have anonymous commenting, but ++ abuse. Either way, spam concerns are completely on your shoulders, and you still have to moderate.

2. Shell out to Disqus or similar. People get to log in with the credentials they already have (and don't have to log in at all if they have cookies from using another Disqus site), moderation is still a thing, but spam is much less of a problem.

3. Not have comments at all. An increasingly popular option.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by shakna on Wednesday April 26, 2017 @08:09PM (#14208150)
> 3 seconds of nonblocking load.

That's a lot. Because Disqus doesn't generally load when the page does.

You have the time the user is reading to load it, but generally Disqus doesn't load till it comes into view.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by mxuribe on Wednesday April 26, 2017 @01:16PM (#14204963)
With so much going on about instant articles (or whatever FB calls them), and some institutions pausing, and thinking if its worth handing over their content (often for free) to these external entities - whose goals may/may not be in alignment, I make a prediction:

* In 5 years time, large organizations (e.g. NY Times) will look far more into self-hosted, often open sourced alternatives. Maybe now, they post to twitter, soon they'll refer users to their own mastodon instance. Now, orgs host comments on disqus, in the future self-hosted platforms like Commento will be used. In some ways, it will go back to the independent way in which things operated back in the late 90s/early 2000s; though hopefully better in other ways. That's my prediction.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by jgaa on Wednesday April 26, 2017 @01:41PM (#14205202)
I really hope you are right :)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by detaro on Wednesday April 26, 2017 @01:19PM (#14204994)
For static sites, a service that takes comments and pushes them to the source repo for the site (or an extra comment-only repo for security and build-performance) could also be interesting.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by drdaeman on Wednesday April 26, 2017 @10:30PM (#14208762)
On the one hand, it could be nice to have it all in a repository or two.

On the other hand, a repo history is normally immutable (with force pushes on rare occasions), and comment spam is way to common. Do you really a repo with all the usual link spam in its commit history? In case of public hosting it may trigger some spam filtering automation and block the repo/account. While perfectly possible, I'm not sure a DVCS repository is a well-matching concept for storage here.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by pomfpomfpomf3 on Wednesday April 26, 2017 @01:53PM (#14205313)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by Sir_Cmpwn on Wednesday April 26, 2017 @03:50PM (#14206350)
I disabled comments on my blog a while ago. Private comments? Email me. Public comments? Write a blog post in response, I'll link to it at the bottom of my article. Improves the quality of the dialogue significantly.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by pryelluw on Wednesday April 26, 2017 @03:55PM (#14206396)
Me too. If I write something that might gain lots of interest in my blog[1], I also post it on dev.to[2] and promote it there. That place has comments and a healthy community.

[1] http://pablojuan.com (https underway)

[2] https://dev.to

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by dawnerd on Wednesday April 26, 2017 @04:42PM (#14206788)
twitter is also another nice option.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by Sir_Cmpwn on Wednesday April 26, 2017 @04:46PM (#14206831)
Would prefer Mastodon/GNUSocial over that.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by ue_ on Wednesday April 26, 2017 @06:38PM (#14207673)
Mastodon really is good, it's fun to use and the fact that you can connect with people on other instances is great.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by foxhop on Wednesday April 26, 2017 @04:43PM (#14206793)
I'm bootstrapping an alternative to Disqus called Remarkbox (https://www.remarkbox.com)

Are you planning on also offering a paid hosted version?

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @04:55PM (#14206903)
I haven't really thought about that. I dunno, would people pay for this? What's a right monthly price for something like that? $3/month? $5/month?

Edit: I know that if I create a SaaS out of this, you'll have me as a direct competition. But can I know more about how you got yours running, what the range the net revenue is in (like, is it over $100/month? Over $1000?)?

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by 0x6c6f6c on Thursday April 27, 2017 @11:34AM (#14212246)
I wouldn't say a flat-rate is exactly correct. Some sites receive tens of thousands of comments on a single article. Others, 5 or 10. The overhead on the service is more likely a better determinant, such as bandwidth and performance requirements for hosting. If SiteA uses 95% of your traffic and SiteB uses 5%, and your overall costs are 200 FakeUnits, you ought to be charging in respect to usage. Starting it at a price that wouldn't impact you negatively would be a good idea, and making it scalable would be even best. I'm moreover just throwing out ideas and thoughts though, I'm no VC or business expert myself, just someone who hosts servers for fun.

Disqus is also paid or supported by ads: https://disqus.com/pricing/

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by foxhop on Wednesday April 26, 2017 @09:46PM (#14208575)
At this point I'm not making anything and I have poking at the idea on the side for 3 years. I'm currently collecting interest by allowing people to register for the beta.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by brango on Wednesday April 26, 2017 @11:34AM (#14203852)
I'd been thinking about doing something like this with AWS API Gateway, Lambda and DynamoDB. Chalice (https://github.com/awslabs/chalice) should make it relatively simple to make and deploy...
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by mwnivek on Wednesday April 26, 2017 @01:16PM (#14204962)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by brango on Wednesday April 26, 2017 @01:28PM (#14205088)
Exactly. Thanks!
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by prophesi on Wednesday April 26, 2017 @11:25AM (#14203730)
This looks nice! I'd also perhaps add very crude deleting functionality; perhaps a way to delete comments via CLI by a unique identifier that is shown on the top right of every comment. Just so that spam posts can be dealt with, without needing a full-blown account system.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by TheAceOfHearts on Wednesday April 26, 2017 @01:18PM (#14204977)
I used Disqus previously, but eventually dropped it because I didn't really have a need for comments and all they entailed. Having a comment system means having to ultimately setup a way to combat bots and spammers, and probably having to do some moderation (depending on the subject). Linking to whatever discussion happens on Hacker News and Reddit is usually good enough. I think that's what pingbacks were supposed to be for?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by _cereal on Wednesday April 26, 2017 @12:17PM (#14204358)
Nice, but how it deals with multiple concurrent writes? I see you are using transactions but, as far as I know, sqlite3 supports database-level locking, so one writing instance, unless using ATTACH and separating tables into multiple files, to enable a sort of table-level locking.

Are you considering to add support to other databases?

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:35PM (#14205706)
>but how it deals with multiple concurrent writes?

I'm afraid I'm not very familiar with how go-sqlite3 handles that. I just started learning golang a month ago, so it's all quite new to me.

Maybe someone else will have a better answer.

>Are you considering to add support to other databases?

At the moment, no. Comments aren't exactly big data ;)

Just curious - which databases would you like to see and why (what do they offer over sqlite)?

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by tyingq on Thursday April 27, 2017 @12:52AM (#14209258)
Single insert per transaction is slow with sqlite, but slow is sort of relative. It would be probably be 10 to 80 inserts per second or so, a little faster if you turn off synchronous writes in sqlite.

I would guess most use cases for this relatively simple comment software wouldn't be expecting that many comments anyway.

An agnostic data layer should probably go on your list, but I imagine other stuff would be higher on the list...like a captcha. Spam will likely be the top issue long before performance.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by Sanddancer on Wednesday April 26, 2017 @11:03PM (#14208871)
I'd say put in an ODBC driver. It gets you support for a lot of databases right out the gate, especially if you keep things to a relatively simple subset. That way, someone already running a postgresql or mysql database can plug things in and not need to track another place data is stored.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by JangoSteve on Wednesday April 26, 2017 @03:22PM (#14206121)
This looks really nice and clean.

I'd been using Juvia a lot over the year's, built by the people at Phusion. It's worked really well, but seems to be unmaintained now.

The killer feature needed in any project like this is spam filtering, which Juvia accomplished by just integrating with Akismet, which works mostly, but not completely.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by mxuribe on Wednesday April 26, 2017 @12:26PM (#14204461)
Add in indieweb functionality to the codebase, such as microformats stuff, and I think this could really catch on. See https://indieweb.org/comments#How_to_markup
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by bshimmin on Wednesday April 26, 2017 @02:01PM (#14205383)
I have literally never heard of IndieWeb. Is this something important I should have heard of?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by zeveb on Wednesday April 26, 2017 @04:21PM (#14206611)
I've mentioned it a few times; I think it's pretty important because it has a bunch of ideas which are our last best hope to prevent the centralisation of the Internet.

Some of their proposals, taken together, could enable people to emulate what Facebook offers, from their own servers.

I'm not 100% onboard with all their ideas, and a few just seem wrong, but all in all I think that they're exciting and important.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by losteric on Wednesday April 26, 2017 @02:10PM (#14205478)
I've been hearing murmurs about it for a while now, I think it's a great idea but thus far it's lacked sufficient business buy-in to gain traction.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by reitanqild on Wednesday April 26, 2017 @02:36PM (#14205713)
Just read and it IMO doesn't seem to need business buy-in, just people who want to have their own domain, write stuff and post it.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @03:30PM (#14206194)
Thanks, I'll look into it.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by aw3c2 on Wednesday April 26, 2017 @12:15PM (#14204332)
Please use a locally hosted js in your example code. rawgit does not even have a privacy policy.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by jacobmischka on Wednesday April 26, 2017 @01:42PM (#14205218)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by kevingrahl on Wednesday April 26, 2017 @08:11PM (#14208155)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Thursday April 27, 2017 @12:16AM (#14209131)
Fixed. Thanks!
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by lol768 on Wednesday April 26, 2017 @01:17PM (#14204971)
Does it include a CAPTCHA? Comment sections seem very susceptible to spam from experience.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:14PM (#14205515)
It doesn't at the moment. But someone filed and issue for this and someone else has already begun work on this!

I <3 open source.

Re:Show HN: Commento: Lightweight, open source, tracking-fre... by bramakris on Wednesday April 26, 2017 @03:38PM (#14206261)
Very nice! Small suggestion for nested comments: If you indent just the left side and not on the right side, there would be a lot more space for these comments, while still retaining the look of a thread hierarchy.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @04:56PM (#14206911)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by Xoros on Wednesday April 26, 2017 @02:23PM (#14205595)
How do you prevent comments flood ? Imagine someone write a script calling your server with valid headers, what will happens ? Serious question I asked myself a month ago on a similar project I tried to put on.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:25PM (#14205613)
At the moment, there's no way. However, Captcha has been suggested. Annoying, but it'll work.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by aembleton on Wednesday April 26, 2017 @04:03PM (#14206464)
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by newsat13 on Wednesday April 26, 2017 @05:14PM (#14207051)
And let google track you instead?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by timbowhite on Wednesday April 26, 2017 @12:52PM (#14204725)
What's the best way to import existing comment data from Disqus into Commento?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:19PM (#14205565)
There's no way atm. Can we export all Disqus comments into JSON? If so, I can probably write a script to convert that into a sequence of SQL statements and generate a `sqlite3.db` file. And if you place that in the root directory, all your comments will appear properly.
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by brilliantcode on Wednesday April 26, 2017 @12:21PM (#14204400)
I'm curious how why you need to initialize a local server? Does that run inside the browser?
Re:Show HN: Commento: Lightweight, open source, tracking-fre... by adtac on Wednesday April 26, 2017 @02:18PM (#14205557)
The `init_commento("http://0.0.0.0:8080")` in the README is an example. You can host your own instance of Commento and just point to that.