As part of a thought experiment, I was thinking about the implications of the internet becoming mainstream in a short time frame. One of the points that came up was the lifecycle of online accounts and their associated data. The lack of a clearly defined lifecycle means that users are at the mercy of each services’ policies. Some services retain data indefinitely, some services sell user data to third parties for ad targeting and most services don’t allow deleting accounts. This is one area where the big tech companies seem reasonable : most allow deleting user accounts and the associated data, but it’s unclear what data deletion really means. What happens to the user data stored in the database backups? What happens to the data shared with third parties? Are they instructed to delete data once the upstream user deletes his account?[Read More]
Building a Disqus alternative Part 2 : The launch
I finally launched Hosted Comments!
After 3 weeks of development, I finally have the first version up and running. You can scroll to the bottom of this page and see it in action.
My initial plan was to blog about the process of building Hosted Comments, but I think I am going to skip the part 1, part 2 style in favour of standalone posts talking about specific challenges of building this software.
So what’s changed since the last post?[Read More]
Building a Disqus alternative Part 1 : Research
What is Disqus?
Some noteworthy features of Disqus:
If you have a Disqus account, you can comment on any website that uses Disqus.
Email notifications with the ability to reply to a comment directly from your email client.
Analytics and moderation tools.
User profiles and ability to follow users
Social network login
A model for a privacy oriented ad network that profiles content, not users
concurrent.futures in Python 3
The concurrent.futures module provides a common high level interface for asynchronously executing callables using pools of threads or processes.
concurrent.futures.Executor is a class to execute function calls asynchronously. The important methods are
submit(function, args), which calls the specified function passing in the given arguments, and
map(function, iterables) which calls the specified function asynchronously passing in each iterable as an argument for a separate function call. This should not be used directly, but is used through its subclasses
Let’s jump into an example. The purpose of the following program is to find the sum of all prime numbers until the given number. There are two functions to demonstrate how to use a pool of threads and how to use a pool of processes.
sum_primes_thread(nums) uses threads and
sum_primes_process(nums) uses processes. Notice that the only difference between the two functions is that one uses
ThreadPoolExecutor while the other uses