Recent blog posts
I was getting the itch to write a small web application and started looking around. I had played with Laravel a while back, but it's just a little too large. I wanted to deploy cheaply on my slow server.
The features I wanted were: REST API support, OAuth (client), Routes, User Auth
Phalcon was the most interesting. It's written in C as an extension, and is fast. It does mostly traditional, Laravel style MVC. It can do REST APIs as well, but the example isn't good. It needs some more code to do REST right. Being compiled it is fast. The features resemble Laravel and Twig.
This is a quick description of my current web dev network that includes a caching proxy server for Debian and Ubuntu packages, and Ansible.
Due to general annoyance with Ubuntu, I started using Debian again, but when I started learning Ansible to set up a staging server, I had to switch back, because Ansible plays nice with Ubuntu. It works with Debian but you need to build from sources.
So, start out by firing up VirtualBox and creating two machines (512M to 1G RAM, 8G disk). Into one, I loaded Debian, but any distro is fine. Debian is just smaller.
This is a short howto about setting up VirtualBox with a Docker environment in it.
Set up a clean Debian VM with the regular install, a 10G disk, and nothing but the SSH server packages. (I have started to just use the Vagrant setup, which uses the username vagrant and password vagrant, in case I want to convert it to a Vagrant image.) Download the VirtualBox Guest Additions CD and, as root, do these things to prep the virtual box to install the drivers.
Run the following.
Several years ago, for the Obama elections, I had to manage a bunch of sign-in sheet info. To perform the data entry, I did a few things to make life easier (for me).
We made a web app with the intent that multiple people could enter data into it. That didn't happen because there wasn't sufficient time to finish the application and then train everyone.
I have been working on March for Bernie on the side, for free of course. It's a WordPress site with a theme from Bernie volunteers.
I must admit that I'm fully drunk on the Kool-Ade.
The tl;dr : testing isn't just writing tests, but also using mock objects and services to simplify testing, and using package managers to port code to new versions of modules. It takes days to learn how, but it's worth it.
If you go to the home page you can add a site-limited google search to your search bar. Google isn't too nice about it, but it'll work.
2010 is upon us, and unlike the Arthur C. Clarke sequel to 2001, wherein the world is exploring space, in the real 2010, the world is trying to find a goddamn job and avoid a huge, double-dip recession and rapid price deflation.
I've been putting ads on here for years, and they have basically failed. On other sites, it's actually OK, making a little trickle of money, which is so weird. Lately, I've been looking at the ads on this site, and sometimes I click them. It's not click fraud because I'm actually interested. So they are working. Then I put up this hideous ad with a big stack of text ads, and I wanted to click more than one of them.
These ads work on me now.
So, I have this library, and it's always a pain to release it onto my internal computers (or any computers). Unlike the web apps it's not running from a virtualenv. It's right on the system. Maybe it shouldn't be :/
Anyway, that was my motivation for learning Python packaging. It's not hard, but you have to follow every step in the tutorials, and really repeat them a few times. After a couple tries, I had my "eggs" working locally. I also found out that I'm supposed to use pip to make "wheels" instead. I was behind the times.
What a confusing topic. Unfortunately, if you start wanting to add "library" features to your code, like I did, you have to study Promises.
These are notes about Parse.Promises, and the end product is a small object that caches models.
The technique here is cool. You can find out how much your eyeballs pivot, and how far apart the lenses need to be.
I got 65mm and 70mm.
Here's a Jasmine spec to instantiate an HTML5 widget and test a few of the method calls. These method calls cause changes in the DOM, and these tests verify that the changes happened.
This is a trick to write modules that are testable in a browser, without subjecting the test to Browserify. Why?
I want to develop without the compilation step. It's easier and faster to work in the browser. (This particular app is mostly DOM manipulation, so headless isn't important.) Once the module has settled down, it can be added to the library.
The rest of this note assumes you know the Jasmine sample test runner included with the distro.
I wrote the original experiment a couple years ago. It's a JS client that retrieves some json data from the la.indymedia.org server, and displays it. I ran out of time, and didn't finish it then.
Upon revisiting the code, I found it a little confusing. It was around 800 lines of jQuery-style JS.