<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/atom10full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><feed xmlns="http://www.w3.org/2005/Atom" xmlns:openSearch="http://a9.com/-/spec/opensearch/1.1/" xmlns:blogger="http://schemas.google.com/blogger/2008" xmlns:georss="http://www.georss.org/georss" xmlns:gd="http://schemas.google.com/g/2005" xmlns:thr="http://purl.org/syndication/thread/1.0" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" gd:etag="W/&quot;DkIGRXg4fSp7ImA9WhBbF0Q.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633</id><updated>2013-05-17T15:42:04.635+03:00</updated><category term="mail" /><category term="postgresql" /><category term="exim4" /><category term="tools" /><category term="grub" /><category term="revision control" /><category term="buildbot" /><category term="wheezy.web" /><category term="benchmark" /><category term="lxc" /><category term="algorithms" /><category term="gnome" /><category term="troubleshooting" /><category term="test" /><category term="audio" /><category term="tftp" /><category term="ldap" /><category term="shell" /><category term="python" /><category term="nginx" /><category term="debian" /><category term="pam" /><category term="windows" /><category term="performance" /><category term="freebsd" /><category term="nfs" /><category term="vim" /><category term="kvm" /><category term="cron" /><category term="nssdb" /><category term="kerberos" /><category term="backup" /><category term="pxe" /><category term="apache" /><category term="linux" /><category term="xfs" /><category term="wheezy.core" /><category term="virtualbox" /><category term="ext3" /><category term="tricks" /><category term="dovecot" /><category term="setuptools" /><category term="xmpp" /><category term="jabber" /><category term="security" /><category term="sftp" /><category term="openssl" /><category term="apt" /><category term="ssh" /><category term="uwsgi" /><category term="django" /><category term="bash" /><category term="ntp" /><category term="tar" /><category term="dns" /><category term="kernel" /><category term="samba" /><category term="qemu" /><category term="network" /><category term="dhcp" /><category term="iptables" /><category term="bugzilla" /><category term="svn" /><title>Mind Reference</title><subtitle type="html">If you want to build a ship, do not drum up the men to gather wood, divide the work and give orders. Instead,
teach them to yearn for the vast and endless sea. — Antoine de Saint-Exupery</subtitle><link rel="http://schemas.google.com/g/2005#feed" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/posts/default" /><link rel="alternate" type="text/html" href="http://mindref.blogspot.com/" /><link rel="next" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default?start-index=26&amp;max-results=25&amp;redirect=false&amp;v=2" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><generator version="7.00" uri="http://www.blogger.com">Blogger</generator><openSearch:totalResults>195</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>25</openSearch:itemsPerPage><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/atom+xml" href="http://feeds.feedburner.com/MindReference" /><feedburner:info uri="mindreference" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>MindReference</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><entry gd:etag="W/&quot;AkEFSXg9fyp7ImA9WhBTEUs.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-1248493015208968868</id><published>2013-02-06T15:30:00.000+03:00</published><updated>2013-02-06T19:36:58.667+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-02-06T19:36:58.667+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.web" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.core" /><title>Thoughts on SQL vs ORM</title><summary type="html">The question of persistence implementation arise often. I found repository pattern very valuable due to separation of concerns, mediate between domain model and data source (mock, file, database, web service, etc). The database data source is somewhat specific since you can proceed with SQL functions or ORM. Here are some thoughts why you might prefer SQL functions over ORM in your next project:
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/iiS-_UPTXkc" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/1248493015208968868/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2013/02/sql-vs-orm.html#comment-form" title="6 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/1248493015208968868?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/1248493015208968868?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/iiS-_UPTXkc/sql-vs-orm.html" title="Thoughts on SQL vs ORM" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>6</thr:total><feedburner:origLink>http://mindref.blogspot.com/2013/02/sql-vs-orm.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A04GQHs9fCp7ImA9WhNbE0k.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-250365355946995838</id><published>2013-01-16T18:00:00.000+03:00</published><updated>2013-01-16T18:25:21.564+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-01-16T18:25:21.564+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.web" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><title>wheezy web: Quick Start i18n Project</title><summary type="html">wheezy.web is a lightweight, high performance, high concurrency WSGI web framework with the key features to build modern, efficient web. Here we will use an i18n (multilingual internationalization) project quick start to build a new project.



Download quickstart-i18n.zip and extract.


Rename extracted directory `quickstart-i18n` to meet your project name, e.g. mysite and open terminal in that &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/NWpZaFugRqQ" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/250365355946995838/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2013/01/wheezy-web-quick-start-i18n-project.html#comment-form" title="6 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/250365355946995838?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/250365355946995838?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/NWpZaFugRqQ/wheezy-web-quick-start-i18n-project.html" title="wheezy web: Quick Start i18n Project" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>6</thr:total><feedburner:origLink>http://mindref.blogspot.com/2013/01/wheezy-web-quick-start-i18n-project.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CUMNQ307fSp7ImA9WhNbEko.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-6985447282786963213</id><published>2013-01-15T21:00:00.000+03:00</published><updated>2013-01-15T21:11:32.305+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-01-15T21:11:32.305+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.web" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><title>wheezy web: Quick Start Empty Project</title><summary type="html">wheezy.web is a lightweight, high performance, high concurrency WSGI web framework with the key features to build modern, efficient web. Here we will use an empty project quick start to build a new project.



Download quickstart-empty.zip and extract.


Rename extracted directory `quickstart-empty` to meet your project name, e.g. mysite and open terminal in that directory.



The empty project &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/mGWhV7mDdsU" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/6985447282786963213/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2013/01/wheezy-web-quick-start-empty-project.html#comment-form" title="4 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6985447282786963213?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6985447282786963213?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/mGWhV7mDdsU/wheezy-web-quick-start-empty-project.html" title="wheezy web: Quick Start Empty Project" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>4</thr:total><feedburner:origLink>http://mindref.blogspot.com/2013/01/wheezy-web-quick-start-empty-project.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DE4CQHo5cCp7ImA9WhNWEkg.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-7273923490663102948</id><published>2012-12-11T22:30:00.000+03:00</published><updated>2012-12-11T23:16:01.428+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-12-11T23:16:01.428+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="security" /><title>How to create Jail in FreeBSD </title><summary type="html">Operating system virtualization is the most effective way to utilize your system resources, jails let you setup isolated mini-systems. Jails are explains well in handbook however, from practical standpoint of view, the presented material is incomplete. Here we will setup few scrips that follow handbook's 'Application of Jails' article and enhance with few missing features. Let note preliminary &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/P4G7suAk-Us" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/7273923490663102948/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/12/freebsd-jail.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7273923490663102948?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7273923490663102948?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/P4G7suAk-Us/freebsd-jail.html" title="How to create Jail in FreeBSD " /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>2</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/12/freebsd-jail.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DU4HQn49cCp7ImA9WhNXFUs.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-5195612948061883643</id><published>2012-12-03T23:30:00.000+03:00</published><updated>2012-12-03T23:52:13.068+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-12-03T23:52:13.068+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="algorithms" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.core" /><title>How to Send Mail in Python</title><summary type="html">There are several use cases how you can send an email message using Python:


Plain Mail: an email message with plain text or html content.
Mail with Attachment: an email message with attached document.
Alternative Mail Views: you provide a convenient way to email recipients to view your message in plain text or html with optional rich content including images, etc.


Here is an example of &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/ndcse1PPzFM" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/5195612948061883643/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/12/python-mail.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/5195612948061883643?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/5195612948061883643?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/ndcse1PPzFM/python-mail.html" title="How to Send Mail in Python" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-Ii3ZtT4CUKY/UL0MPbUJ-ZI/AAAAAAAAANw/GhPELYn9U3g/s72-c/python-alternative-mail.png" height="72" width="72" /><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/12/python-mail.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DE8BRXg-fyp7ImA9WhNXEU8.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-9123540027014001216</id><published>2012-11-28T21:00:00.000+03:00</published><updated>2012-11-28T21:20:54.657+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-28T21:20:54.657+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="setuptools" /><title>How to ship eggs with pyo files only in Python</title><summary type="html">There is sometimes a need to ship python egg distribution with pyo files only. There is confusion using bdist_egg command since it doesn't have any options to do that; instead, you can instruct install_lib command. Here is what you need in setup.cfg file:


[install_lib]
compile = 0
optimize = 2

[bdist_egg]
exclude-source-files = 1


Issue the following command to build egg.


python setup.py -q&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/b1bjGQCkooE" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/9123540027014001216/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/11/python-egg-pyo.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/9123540027014001216?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/9123540027014001216?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/b1bjGQCkooE/python-egg-pyo.html" title="How to ship eggs with pyo files only in Python" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/11/python-egg-pyo.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CE8ER3Y_eip7ImA9WhNQFE4.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-910826835935929467</id><published>2012-11-20T20:30:00.000+03:00</published><updated>2012-11-20T20:33:26.842+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-20T20:33:26.842+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Web Frameworks Excessive Complexity</title><summary type="html">Cyclomatic (or conditional) complexity is a metric used to indicate the complexity of a source code. In this post we will take a look at web frameworks source code and estimate excessive complexity, something that is beyond recommended level of 10 (threshold that points to the fact the source code is too complex and refactoring is suggested). Here is a list of web frameworks examined:


bottle
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/ncB9o-5f4FE" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/910826835935929467/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/11/python-web-excessive-complexity.html#comment-form" title="20 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/910826835935929467?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/910826835935929467?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/ncB9o-5f4FE/python-web-excessive-complexity.html" title="Python Web Frameworks Excessive Complexity" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-ae-02u4Trfs/UKu2hpea85I/AAAAAAAAANY/LHsisZkaT4w/s72-c/python-web-excessive-complexity.png" height="72" width="72" /><thr:total>20</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/11/python-web-excessive-complexity.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DUMARn45fCp7ImA9WhNQEE0.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-2692561528968248338</id><published>2012-11-15T22:00:00.000+03:00</published><updated>2012-11-15T22:24:07.024+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-15T22:24:07.024+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="algorithms" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.core" /><title>Lazy Attribute in Python</title><summary type="html">A lazy attribute is an attribute that is calculated on demand and only once. Here we will see how you can use lazy attribute in your Python class. Setup environment before you proceed:


$ virtualenv env
$ env/bin/pip install wheezy.core


Let assume we need an attribute that is display name of some person

Place the following code snippet into some file and run it:


from wheezy.core.descriptors&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/gDv1vISgX0M" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/2692561528968248338/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/11/python-lazy-attribute.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2692561528968248338?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2692561528968248338?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/gDv1vISgX0M/python-lazy-attribute.html" title="Lazy Attribute in Python" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>2</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/11/python-lazy-attribute.html</feedburner:origLink></entry><entry gd:etag="W/&quot;D0QBQHwzeCp7ImA9WhNRE0Q.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-6974201124883091462</id><published>2012-11-08T20:00:00.000+03:00</published><updated>2012-11-08T20:22:31.280+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-08T20:22:31.280+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="algorithms" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.core" /><title>Duck Typing Assert in Python</title><summary type="html">People who come from strongly typed languages that offer interfaces often are confused by lack of one in Python. Python, being dynamic typing programming language, follows duck typing principal. Here we will see how programmer can assert duck typing between two Python classes. Setup environment before proceed:


$ virtualenv env
$ env/bin/pip install wheezy.core


Let play a bit with duck test `&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/5n5LvIxrMpY" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/6974201124883091462/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/11/python-duck-typing-assert.html#comment-form" title="10 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6974201124883091462?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6974201124883091462?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/5n5LvIxrMpY/python-duck-typing-assert.html" title="Duck Typing Assert in Python" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>10</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/11/python-duck-typing-assert.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0QAQX89fCp7ImA9WhNRE0Q.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-4359421357331636100</id><published>2012-11-03T00:00:00.000+03:00</published><updated>2012-11-08T19:15:40.164+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-08T19:15:40.164+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="algorithms" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.core" /><title>How to generate account number?</title><summary type="html">Requirements for `account number` generator:

Issue pseudo random consistent number (must be unique for dozen millions of records)
Easy check validity (without a need to make a database call)

We will use Feistel cipher to generate pseudo random number (positive only) from a sequential numbers (e.g. returned by nextval() for a posgresql sequence). This algorithm is taken as basis for the `&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/UPszYmHOX0I" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/4359421357331636100/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/11/generate-account-number.html#comment-form" title="3 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/4359421357331636100?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/4359421357331636100?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/UPszYmHOX0I/generate-account-number.html" title="How to generate account number?" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>3</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/11/generate-account-number.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkAGQXg7eCp7ImA9WhNSEkg.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-3152756438724897488</id><published>2012-10-26T14:00:00.000+03:00</published><updated>2012-10-26T15:32:00.600+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-26T15:32:00.600+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="wheezy.web" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><title>wheezy web: introduction</title><summary type="html">The key of success for any medium to high complexity system is in separation of domain concerns. Given that choice in architectural design for web framework, the development activities are split by distinct, non-dependent parts. The wheezy.web is a lightweight WSGI web framework and serves a glue purpose between various other packages developed under wheezy.* umbrella in loosely coupled way, it &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/nb6XQXQo0Qw" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/3152756438724897488/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/wheezy-web-introduction.html#comment-form" title="3 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/3152756438724897488?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/3152756438724897488?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/nb6XQXQo0Qw/wheezy-web-introduction.html" title="wheezy web: introduction" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>3</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/wheezy-web-introduction.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkACRns4cSp7ImA9WhNSGEg.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-672223474883059771</id><published>2012-10-25T16:30:00.000+03:00</published><updated>2012-11-02T14:12:47.539+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-02T14:12:47.539+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Web Caching Benchmark</title><summary type="html">Content caching is the most effective type of cache. This way your web handler is not executed to determine a valid response to user, instead one returned from cache. Since the operation is that simple, it should be the maximum possible speed your `real world` application capable to provide. There are several use cases when content caching is applicable:


Site: the site content is changed rarely&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/K8B-NL4kRN0" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/672223474883059771/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/python-web-caching-benchmark.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/672223474883059771?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/672223474883059771?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/K8B-NL4kRN0/python-web-caching-benchmark.html" title="Python Web Caching Benchmark" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-KnHGVZOZPT8/UJOpxNCPqtI/AAAAAAAAAMo/E9Ey1USIic8/s72-c/python-web-caching-benchmark.png" height="72" width="72" /><thr:total>2</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/python-web-caching-benchmark.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CEEMSXc_fSp7ImA9WhNVE0k.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-7011164775159907421</id><published>2012-10-23T15:30:00.000+03:00</published><updated>2012-12-24T12:51:28.945+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-12-24T12:51:28.945+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Templates Benchmark</title><summary type="html">Python template engines offer high reusability of markup code and the following features are used by content developers most of the time:



Includes: useful to incorporate some snippets of content that in most cases are common to the site, e.g. footer, scripts, styles, etc.



Extends: useful to define a master layout for the majority of the site content with placeholders, e.g. sidebar, &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/ZtOWignRXc0" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/7011164775159907421/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/python-templates-benchmark.html#comment-form" title="9 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7011164775159907421?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7011164775159907421?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/ZtOWignRXc0/python-templates-benchmark.html" title="Python Templates Benchmark" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://4.bp.blogspot.com/-9kNAqQUKdPk/UNglHG_p81I/AAAAAAAAAOk/tzULdN34XRU/s72-c/python-templates-benchmark1.png" height="72" width="72" /><thr:total>9</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/python-templates-benchmark.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0cDQXo8fCp7ImA9WhNbF0s.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-8756150769244668190</id><published>2012-10-18T15:00:00.000+03:00</published><updated>2013-01-21T12:37:50.474+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-01-21T12:37:50.474+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Web Frameworks PEP8 Consistency</title><summary type="html">The code is read much more often than it is written. The PEP8 guidelines are intended to improve the readability of code. Readability counts, no doubt, but readability consistency is important, it is equally important to know when to be inconsistent. The report below makes excuse for the following:


E501 line too long (&amp;gt; 79 characters)
E231 missing whitespace after ',:'
W291 trailing whitespace
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/o_Eje2Pw0mA" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/8756150769244668190/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/python-web-pep8-consistency.html#comment-form" title="6 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8756150769244668190?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8756150769244668190?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/o_Eje2Pw0mA/python-web-pep8-consistency.html" title="Python Web Frameworks PEP8 Consistency" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-26fWBFkvXNg/UP0MRKPamrI/AAAAAAAAAPI/pCwuc-inuXw/s72-c/python-web-pep8-consistency.png" height="72" width="72" /><thr:total>6</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/python-web-pep8-consistency.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ck4DQ385fSp7ImA9WhNTE0w.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-6389852491137441857</id><published>2012-10-15T17:00:00.000+03:00</published><updated>2012-10-15T17:22:52.125+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-15T17:22:52.125+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="debian" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Web Reverse URLs Benchmark</title><summary type="html">How fast python web frameworks reverse urls? While routing is a mapping of incoming request to a handler, url reverse function is designed to build urls for those handlers. A web page may have a number of urls from few dozen to hundreds... all related to your web site (e.g. links between related pages, tag cloud, most viewed posts, etc). A typical web application usually has deal with the &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/1lYGNPf5B-g" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/6389852491137441857/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/python-web-reverse-urls-benchmark.html#comment-form" title="2 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6389852491137441857?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/6389852491137441857?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/1lYGNPf5B-g/python-web-reverse-urls-benchmark.html" title="Python Web Reverse URLs Benchmark" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://1.bp.blogspot.com/-xeOAqWHnF7Y/UHwMARgBiKI/AAAAAAAAAIQ/T2tbRwXi1hA/s72-c/python-web-urls-benchmark.png" height="72" width="72" /><thr:total>2</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/python-web-reverse-urls-benchmark.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CEIFQHY9cSp7ImA9WhNQFEw.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-5236894606410871781</id><published>2012-10-09T16:30:00.000+03:00</published><updated>2012-11-20T14:55:11.869+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-11-20T14:55:11.869+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="debian" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Web Routing Benchmark</title><summary type="html">How fast python web framework process routing (some calls this URL dispatch)? A typical web application usually has the following routes:

Static: the URL path is fixed and never changes, e.g. https://bitbucket.org/explore.

Dynamic: the URL path is constructed dynamically and can include semantic information, e.g. https://bitbucket.org/jsmith/dotfiles/downloads, in this case jsmith is user, &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/sp-7TyRap9k" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/5236894606410871781/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/python-web-routing-benchmark.html#comment-form" title="20 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/5236894606410871781?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/5236894606410871781?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/sp-7TyRap9k/python-web-routing-benchmark.html" title="Python Web Routing Benchmark" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://3.bp.blogspot.com/-yCye2nXU-3w/UKtvh6_q7vI/AAAAAAAAANA/gXCfzGxgodQ/s72-c/python-web-routing-benchmark.png" height="72" width="72" /><thr:total>20</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/python-web-routing-benchmark.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0AHQXcycCp7ImA9WhJaFE8.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-2497401424108780250</id><published>2012-10-04T20:30:00.000+03:00</published><updated>2012-10-05T12:35:30.998+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-10-05T12:35:30.998+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="debian" /><category scheme="http://www.blogger.com/atom/ns#" term="apt" /><title>apt-get: update only required translations</title><summary type="html">apt Acquire::Languages can be set to declare which translations you want downloading. The variable "environment" specifies that apt should check $LC_MESSAGES. Here we go:


# eliminate any lists you might have
rm -rf /var/lib/apt/lists/
# set languages you need
echo 'Acquire::Languages { "environment"; "en"; };' &amp;gt; \
  /etc/apt/apt.conf.d/99lang
# update lists
apt-get update


If you need just &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/2jfvjq7NVW4" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/2497401424108780250/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/10/apt-translations.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2497401424108780250?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2497401424108780250?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/2jfvjq7NVW4/apt-translations.html" title="apt-get: update only required translations" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/10/apt-translations.html</feedburner:origLink></entry><entry gd:etag="W/&quot;A0MMQnk7eSp7ImA9WhBVEE8.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-8217100692097039226</id><published>2012-09-18T15:00:00.000+03:00</published><updated>2013-04-15T15:38:03.701+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-04-15T15:38:03.701+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="django" /><category scheme="http://www.blogger.com/atom/ns#" term="debian" /><category scheme="http://www.blogger.com/atom/ns#" term="python" /><category scheme="http://www.blogger.com/atom/ns#" term="uwsgi" /><category scheme="http://www.blogger.com/atom/ns#" term="benchmark" /><title>Python Fastest Web Framework</title><summary type="html">What is the fastest web framework for Python? In this post we will examine a trivial 'Hello World!'. See also:

Performance Benchmarks
Routing
Reverse URLs
Caching

Code Quality
PEP8 Consistency
Excessive Complexity

Template Engines
Big Table
Includes, extends and widgets



The application (see source) is written for various Python web frameworks  and deployed to uWSGI application container (&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/4kIQ4U8egU4" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/8217100692097039226/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/09/python-fastest-web-framework.html#comment-form" title="32 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8217100692097039226?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8217100692097039226?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/4kIQ4U8egU4/python-fastest-web-framework.html" title="Python Fastest Web Framework" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><media:thumbnail xmlns:media="http://search.yahoo.com/mrss/" url="http://2.bp.blogspot.com/-F7bNC9bLyYk/UWvnsXkPBMI/AAAAAAAAAPk/ek74Vuzy34A/s72-c/python-fastest-web-framework.png" height="72" width="72" /><thr:total>32</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/09/python-fastest-web-framework.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0INRX0_cCp7ImA9WhJWF0w.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-8119174826159145095</id><published>2012-08-22T20:00:00.000+03:00</published><updated>2012-08-23T11:46:34.348+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-23T11:46:34.348+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="troubleshooting" /><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="vim" /><title>How to restore vim screen when exiting</title><summary type="html">When you exit vim it does not restore the terminal screen (particularly in FreeBSD), here is how to fix that (file ~/.vimrc):


" Restore terminal screen when exiting Vim
if &amp;amp;term =~ "xterm"
  let &amp;amp;t_ti = "\&amp;lt;Esc&amp;gt;[?47h"
  let &amp;amp;t_te = "\&amp;lt;Esc&amp;gt;[?47l"
endif
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/6JaIQLlgNdo" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/8119174826159145095/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/vim-restore-screen.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8119174826159145095?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8119174826159145095?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/6JaIQLlgNdo/vim-restore-screen.html" title="How to restore vim screen when exiting" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/vim-restore-screen.html</feedburner:origLink></entry><entry gd:etag="W/&quot;Ak8FQHw_fSp7ImA9WhNWE00.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-4345688276105970377</id><published>2012-08-19T21:00:00.000+03:00</published><updated>2012-12-12T13:40:11.245+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-12-12T13:40:11.245+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="security" /><title>Rebuilding World and Kernel on FreeBSD</title><summary type="html">Building the world and kernel on FreeBSD is just few steps procedure. The Handbook explains everything in great details. Here is short version.




Synchronize the OS source code (see here).



Configure make.conf.


Optional. Configure world options (file /etc/src.conf):

WITHOUT_AMD=
WITHOUT_ASSERT_DEBUG=
# Need only few utilities from bind
WITHOUT_BIND_DNSSEC=
WITHOUT_BIND_ETC=
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/R0CpqUI_RDE" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/4345688276105970377/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-build-world-kernel.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/4345688276105970377?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/4345688276105970377?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/R0CpqUI_RDE/freebsd-build-world-kernel.html" title="Rebuilding World and Kernel on FreeBSD" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-build-world-kernel.html</feedburner:origLink></entry><entry gd:etag="W/&quot;CUcMR3kzfCp7ImA9WhNWE0k.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-8589933877388786508</id><published>2012-08-19T20:30:00.000+03:00</published><updated>2012-12-12T23:11:26.784+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-12-12T23:11:26.784+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><title>Keep FreeBSD up to date with csup</title><summary type="html">csup is a simple tool to keep you FreeBSD source and/or ports collection up to date (rewrite of CSVup in C). There are a number of mirrors around the world hosting the source code and you need to select one that is closest to your location. Use a tool like traceroute to find a one that responds best (shortest path, low delays).

Ports
It is recommended to copy ports configuration file (known as &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/nTTNsXmt-gM" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/8589933877388786508/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-csup-update.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8589933877388786508?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8589933877388786508?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/nTTNsXmt-gM/freebsd-csup-update.html" title="Keep FreeBSD up to date with csup" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-csup-update.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0YGRH07eCp7ImA9WhJWFEg.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-8937587669032735946</id><published>2012-08-19T20:00:00.000+03:00</published><updated>2012-08-20T11:25:25.300+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-20T11:25:25.300+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="security" /><title>FreeBSD Binary/Security Updates</title><summary type="html">freebsd-update is a tool to fetch and update binary security patches for official releases. e.g. FreeBSD 9.0-RELEASE. Once you made fresh OS install this is the way to update your system quickly.


freebsd-update fetch
freebsd-update install


Note, this tool doesn't work if you build world/kernel from source.&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/LsQXx3RMk7g" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/8937587669032735946/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-binary-update.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8937587669032735946?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/8937587669032735946?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/LsQXx3RMk7g/freebsd-binary-update.html" title="FreeBSD Binary/Security Updates" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-binary-update.html</feedburner:origLink></entry><entry gd:etag="W/&quot;DkIGRXg_fyp7ImA9WhBbF0Q.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-3405526463743252931</id><published>2012-08-18T19:00:00.000+03:00</published><updated>2013-05-17T15:42:04.647+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2013-05-17T15:42:04.647+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><title>FreeBSD make.conf example</title><summary type="html">make.conf stores system-wide build settings that apply each time you run make. Copy example:


cp /usr/share/examples/etc/make.conf /etc


Compile the source code specific to your CPU:

CPUTYPE?=native

It is recommended uncomment the following: CFLAGS, CXXFLAGS, COPTFLAGS.

# 2 jobs per CPU
MAKE_JOBS_NUMBER=4

# KNOBS -- A list of popular knobs and their descriptions
# http://svn.freebsd.org/&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/pnGW7mzq6EE" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/3405526463743252931/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-makeconf.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/3405526463743252931?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/3405526463743252931?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/pnGW7mzq6EE/freebsd-makeconf.html" title="FreeBSD make.conf example" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-makeconf.html</feedburner:origLink></entry><entry gd:etag="W/&quot;AkEHSHY_fSp7ImA9WhJWFEg.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-2946632872834512224</id><published>2012-08-18T18:30:00.000+03:00</published><updated>2012-08-20T13:30:39.845+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-20T13:30:39.845+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="tricks" /><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="security" /><title>How to setup HTTP Proxy in FreeBSD</title><summary type="html">The HTTP proxy is set through environment variable HTTP_PROXY. Environment variables can be controlled during user login. Assuming the proxy is proxy.somewhere.net:3128 ensure the following in /etc/login.conf:


:setenv=HTTP_PROXY=http\c//proxy.somewhere.net\c3128:\


Update login capability database:

cap_mkdb /etc/login.conf


Re-login and ensure it is properly set:

env | grep HTTP_PROXY
&lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/EJ6LjiBqWH4" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/2946632872834512224/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-http-proxy.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2946632872834512224?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/2946632872834512224?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/EJ6LjiBqWH4/freebsd-http-proxy.html" title="How to setup HTTP Proxy in FreeBSD" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-http-proxy.html</feedburner:origLink></entry><entry gd:etag="W/&quot;C0YASX8yeyp7ImA9WhJWFU4.&quot;"><id>tag:blogger.com,1999:blog-8404509726009905633.post-7022469273401382303</id><published>2012-08-18T18:00:00.000+03:00</published><updated>2012-08-21T09:39:08.193+03:00</updated><app:edited xmlns:app="http://www.w3.org/2007/app">2012-08-21T09:39:08.193+03:00</app:edited><category scheme="http://www.blogger.com/atom/ns#" term="freebsd" /><category scheme="http://www.blogger.com/atom/ns#" term="security" /><category scheme="http://www.blogger.com/atom/ns#" term="pam" /><title>How to SU with no password in FreeBSD</title><summary type="html">You can allow user to switch to root account without password. You need to add user to wheel group:


pw usermod john -G wheel


and change pam policy (file /etc/pam.d/su):


#auth            requisite       pam_group.so            no_warn group=wheel root_only fail_safe ruser
auth            sufficient      pam_group.so            no_warn group=wheel root_only fail_safe ruser


It is necessary &lt;img src="http://feeds.feedburner.com/~r/MindReference/~4/kk13_1gRZZ0" height="1" width="1"/&gt;</summary><link rel="replies" type="application/atom+xml" href="http://mindref.blogspot.com/feeds/7022469273401382303/comments/default" title="Post Comments" /><link rel="replies" type="text/html" href="http://mindref.blogspot.com/2012/08/freebsd-su-no-password.html#comment-form" title="0 Comments" /><link rel="edit" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7022469273401382303?v=2" /><link rel="self" type="application/atom+xml" href="http://www.blogger.com/feeds/8404509726009905633/posts/default/7022469273401382303?v=2" /><link rel="alternate" type="text/html" href="http://feedproxy.google.com/~r/MindReference/~3/kk13_1gRZZ0/freebsd-su-no-password.html" title="How to SU with no password in FreeBSD" /><author><name>Andriy Kornatskyy</name><uri>http://www.blogger.com/profile/04890869628175359888</uri><email>noreply@blogger.com</email><gd:image rel="http://schemas.google.com/g/2005#thumbnail" width="32" height="30" src="http://3.bp.blogspot.com/_sgeB1kMLDYc/S88hM1GCGNI/AAAAAAAAAAM/R7j2TxpuJlQ/S220/DSC00132.JPG" /></author><thr:total>0</thr:total><feedburner:origLink>http://mindref.blogspot.com/2012/08/freebsd-su-no-password.html</feedburner:origLink></entry></feed>
