Another excellent photo series on Boston.com
Page 67
Page 67
Another excellent photo series on Boston.com
An awesome piece of Javascript code. Well done!
Is it just me or is this just another proof that the film "Wall·E":http://www.imdb.com/title/tt0910970/ predicts the future, ie. that a couple of generations from now we'll be fat, lazy and living in space.
What's interesting about this article is that they even mention Chinese people become obese. I've heard it before, that other Europeans are getting Obese too but now it's Chinas turn to get some blame light.
"In Mexico, nobody was overweight 15 years ago; now 71 percent of Mexican women and 66 percent of men are."
Just put in the remaining necessary cache headers on my kungfu club mobile site and I ran a YSlow! test on it and it got a 100! I've never had that before.
Admittedly, this is like cheating since the site is for mobile use it's kept very very simple and has no external dependencies so no need for a CDN. Getting a Grade A on YSlow! is very hard if the site needs to really blink. This one is built dedicated for small mobile phone screens on slow connections. I think now the bottleneck isn't in the rendering but in the connection latency for the remote database.
It also got a 4.9 (max 5.0) on ready.mobi which is the highest I've ever achieved there.
Truncated! Read the rest by clicking the link below.
Is this fake or the most disgusting ad ever?
Cute Web 2.5 song
For the impatient: Jed and Wing IDE are programming editors I use for my Python, Javascript, HTML, CSS editing. One is ultra-light, fast and simple. The other one is very feature full, commercial and slow (in comparison to Jed).
I've been using Jed now for several years on Linux. It's an "Emacs clone" 1 in that almost the same key bindings you have in Emacs work in Jed. A few weeks ago I started using Wing IDE 3.1 instead to see if I could learn to love it. I got a professional license as a gift for participating in the PyCon 2008 sprint by Wingware (the company behind Wing IDE). As of yesterday I've gone back to Jed but I haven't uninstalled Wing yet. Here are what I've learned from using both quite a bit. Note, I'm not comparing things that they both do equally well such as macros, community support and block indentation.
Truncated! Read the rest by clicking the link below.
Caching in Django absolutely rocks. Much so because of its simplicity which lowers the threshold to the height of a snowflake. However the simplicity can cause some unexpected surprises.
I ran my site and clicked around until I found a bug I wanted to fix. Then I wrote the test and ran the testrunner but I was getting some really weird behavior. The view looked like this:
@never_cache
def club_page(request, clubname):
club = _find_club(clubname)
if club is None:
raise Http404('Could not find the club')
classes = cache.get('club_page_classes')
if classes is None:
classes = ClubClass.objects.filter(club=club).order_by('start_time')
cache.set('club_page_classes', classes, CACHE_TIMEOUT)
...
What happened (and what took me a while to figure out) was that the memcache was still active and being used when running the tests since it's only within the hour that I started running the tests with completely different data. Here's how I solved the problem:
class ViewsTestCase(unittest.TestCase):
...
def test_club_page(self):
""" test rendering the club page """
cache.delete('club_page_classes')
...
There must be an easier way to patch the testrunner to reset all cache before running the tests. Anybody?