Sunday, January 15, 2017

A year with Tor

Looking back at 2016

As a follow-up to my previous post (which described how and why I use Tor) let's now take a look back at year 2016 and squeeze out some interesting information out of collected logs.

So that's what this post is about: numbers, used nodes and a map describing my usage of Tor in last 12 months.

Saturday, July 30, 2016

PostgreSQL + SQLAlchemy: accent and case insensitive search

Ignore accents & case

Maybe you know what it's like: you store UTF-8 encoded text/strings in your database but you want to be able to execute an ASCII based query ignoring all those pesky diacritics. It's not always straightforward.

The following tutorial is a compilation of 3 StackOverflow posts and it describes how to perform an accent and case insensitive search with PostgreSQL and SQLAlchemy.

Thursday, February 11, 2016

Tor IP changing and web scraping

Anonymous web scraping

Many of us who scrape web pages, be it for fun, data, love or something else, are concerned about anonymity. Well, not anonymity per se, we just don't want our IP blacklisted.

Many of us choose Tor and its network to achieve our goal. In this post I am going to share my experience and observations using Tor + Privoxy for Python driven web scraping.

Tuesday, December 15, 2015

Atom editor and Perforce integration on Linux (Mac)

Atom for editing, Perforce for version control

Atom is a really cool text editor developed by GitHub. It is modern, lightweight, fast, provides it's own package manager and tons of packages/plugins as well. Though, if you are using Perforce for version control, things may get a bit bitter.

This short post provides an easy and elegant fix for integrating Atom with Perforce on a Linux (Mac) machine. It solves the problem when the atom-perforce package is unable to pick the right p4 client.

Tuesday, October 20, 2015

SyntaxHighlighter on Blogger and an unexpected output in a Python snippet

Syntax highlighting on Blogger

I was looking for an easy way to add syntax highlighting to my code snippets here on Blogger. Yes, you can embed Gist code snippets, but this approach is not ideal always. There must be a better way for doing this. And of course there is!

I found SyntaxHighlighter after a few minutes of googling. It does exactly what I want, it's easy to use, supports many syntaxes and is nicely documented. But, for some Python code, it is doing a bit more than it should.