Blog Archive, October 2016

Featured Image

Executing Parallel Tasks in Python with concurrent.futures

 Oct. 31, 2016    0 comments 

Recently I discovered for myself the concurrent.futures Python module. It is the part of the standard library in Python 3 and for Python 2 it can be downloaded from PyPI. This module allows to run multiple time-consuming tasks in parallel in different threads or processes and then to collect the result of those tasks for future use. (...)

Read post

 Python

Featured Image

Django/Jinja2 Language Definition for Prism.js

 Oct. 26, 2016    0 comments 

Recently I made some improvements to this blog CMS in order to better handle code samples in various programming languages. One of the improvements is a brand-new language definition for Prism syntax highlighter. Prism is an easy to use JavaScript library for in-browser code syntax highlighting that supports many languages (programming, markup, configuration etc.). Unfortunately, Django template languages was not among them so I decided to fill-in this gap. And because Jinga2 template syntax is very similar, I decided to make one language definition for both. (...)

Read post

 DjangoJavaScript

Featured Image

Recent surprise

 Oct. 13, 2016    0 comments 

Quite a while ago I created a GUI micro-famework for Kodi mediacenter (formerly XBMC). At that time I tried to develop a subtitle addon for Addic7ed.com (which I did) and I needed to create a UI for the addon. Previously subtitle addons in Kodi had to have their own UI, so I used a several classes that Kodi-Python API provides and created a UI for my addon. Inspired with success (those were my first attempts to write something useful in Python) I decided to extend that UI to a micro-framework that would allow to create user interfaces for Kodi addon in pure Python without messing with XML skinning. I published my micro-framework on GitHub, submitted it to the Kodi official addon repository and created a topic on the Kodi official forum. I also used it in a couple of my personal projects, and that was all. (...)

Read post

 KodiPython