Achievments in 2016

| Comments

A list of my most important achievments in 2016:

  • started a new job at MailInBlack, like it.
  • used a lot of different technologies: flask, celery, angular, mondodb, scala, docker, azure & google clouds, google app engine

Migrate from octopress to hugo

| Comments

As usual at the beginning of the year I decided to continue the blog, but I was on a new macbook with a fresh system and also I forgot how to use octopress. So, why not to try something new.

NGINX for static files for dev python server

| Comments

When you work on the backend part of django or flask project and there are many static files, sometimes the development server becomes slow. In this case it’s possible to use nginx as reverse proxy to serve static. I’m using nginx in docker and the configuration is quite simple.

strftime for datetime before 1900 year

| Comments

Recently I’ve got an error for birthdays before 1900 year

ValueError: year=1890 is before 1900; the datetime strftime() methods require year >= 1900

for this code:

import datetime,7,1).strftime('%d.%m.%Y')

And it’s described in the documentation > The full set of format codes supported varies across platforms, because Python calls the platform C library’s strftime() function, and platform variations are common. To see the full set of format codes supported on your platform, consult the strftime(3) documentation.
> The exact range of years for which strftime() works also varies across platforms. Regardless of platform, years before 1900 cannot be used.

One of the ways to solve this:

birthday =,7,1)

Test django view with cookies

| Comments

To test some view which use cookies:

from Cookie import SimpleCookie
from django import test

class SomeTest(test.TestCase):

    def test_some_view(self):
        self.client.cookies = SimpleCookie({'test_cookie': 'test_value'})
        response = self.client.get('/some-url/')

        self.assertEqual(response.client.cookies['test_cookie'].value, 'test_value')

My current tools

| Comments

MacBook Air 13” instead of iMac 24” 2007
It’s faster and provides me mobility, but I’m lacking in screen size, I plan to solve this with external monitor.

Sublime Text3 with next packages:

  • package control
  • djaneiro (django support)
  • django-docsearch
  • git (checkout branch python3)
  • jsformat
  • modific (highlighting lines changed since the last commit)
  • sidebar enchancement
  • sublimelinter (checkout sublime-text-3 branch)
  • theme phoenix

Before this I used PyCharm, it’s very good, but slower.

SourceTree - GUI for Git and Mercurial
I prefer to use command line to add, commit, push and this app for history. It’s a little slow sometimes.

OmniFocus for GTD
Usually I use just two perspectives Business and Personal grouped by due date. It’s useful to have filled estimate field, it gives me possibility to better plan my day.

Toggl for time tracking
Good reports, desktop and iphone apps, I know how I spent my time.

nvALT for notes
Simple and fast.

It looks like a spotlight but much better. I’m using mostly for clipboard history and to:

  • open apps
  • paste notes to nvALT
  • find files
  • calculate
  • search contacts
  • change status in Skype and Messages simultaneously
1/2 »