Latest entries


Other channels of distribution for STARLIMS utilities

All utilities related to STARLIMS from this website will be moved to a private location (I don't know where right now, but it might be the STARLIMS forum, STARLIMS Intranet or another STARLIMS internal site).

If you are a STARLIMS affiliate you will still be able to use the utilities and you will be able to stay up-to-date with all new developments...Just use the official/internal channels...

Also, all articles related to these tools will not be active on this site anymore.

Posted on March 30, 2009 | 0 comments


Comcast DNS sucks - Host not found errors

In the past few days I started having problems at home with my internet connection. For every page that I was trying to visit I would get, most of the times, a "Host not found" error and after refreshing a couple of times then the page would finally load up.

Initially I thought this to be a Windows problem so I played with the settings of the DNS Client but to no success. I also rebooted my router and modem a few times, again, without solving anything. Then, I remembered that my problems started just after installing Sun's VirtualBox and setting up a Ubuntu machine. I thought that maybe one of the devices VirtualBox installed broke something in Windows. After disabling the devices, completely removing them and even uninstalling VirtualBox, the problem was still there.

Finally, after giving it more thought, I configured my router to use the free OpenDNS service and all my issues were gone. No more errors, no more refreshing every page at least 4 times for it to load, no more gray hairs. Just by changing the DNS servers used by the router I got rid of all the problems. With OpenDNS you even get additional services, so it's no brainer that that's what I will keep using for the rest of my Comcast cable internet user days.

Posted on February 6, 2009 | 0 comments


Greate advances in interfacing man and machine through thought

From CBS' 60 Minutes:

People who are completely paralyzed due to illness or trauma are getting help communicating with a new technology that connects their brains to a computer.


Watch CBS Videos Online

Posted on November 4, 2008 | 1 comment


The Python Paradox

I recommend this very interesting read from Paul Graham regarding non-mainstream programming languages.

Quote:

It's a lot of work to learn a new programming language. And people don't learn Python because it will get them a job; they learn it because they genuinely like to program and aren't satisfied with the languages they already know.

Which makes them exactly the kind of programmers companies should want to hire. Hence what, for lack of a better name, I'll call the Python paradox: if a company chooses to write its software in a comparatively esoteric language, they'll be able to hire better programmers, because they'll attract only those who cared enough to learn it. And for programmers the paradox is even more pronounced: the language to learn, if you want to get a good job, is a language that people don't learn merely to get a job.

Makes you feel good for knowing Python...

[The Python Paradox via Corey Goldberg's blog]

Posted on October 30, 2008


Plastic Logic reader

Finally, an e-book reader that seems useful, practical and cool-looking.

[via hardocp]

Posted on September 12, 2008


TDD and Hard-To-Test Areas

Ian Cooper talks about the issues people get when they begin working with Test-Driven Development and what makes them abandon TDD after an initial experiment. His articles (part 1, part 2) are a good read for anyone interested in TDD. Also you will find in his posts a few good references for further reading.

Posted on September 11, 2008


How to: visit password-protected websites without registering

Some sites allow googlebot to index their content but require regular users to register/login. So, if you don't want to register in order to see the content of such a site, you can just change the User Agent of your browser to Googlebot (in Firefox you can do that using the User Agent Switcher plugin).

[How to: visit password-protected websites without registering via reddit]

Posted on August 27, 2008


What's On Olympian Kerri Walsh's Shoulder?

I was curious about that... Here's the answer: What's On Olympian Kerri Walsh's Shoulder? (via Gizmodo).

Posted on August 17, 2008


Freebase Parallax: A new way to browse and explore data

Freebase Parallax is a browsing interface for Freebase that greatly enhances the way we search for linked data. Watch the video below for a very cool demo.


Freebase Parallax: A new way to browse and explore data from David Huynh on Vimeo.

Posted on August 17, 2008


Django generic views cache-like behavior

In certain cases the Django generic views will behave like they are caching data. They are doing that for the queryset argument and not for extra_context which is known to be cached. This will happen if you send to the generic view a queryset filtered with a callable.

Let's take as an example a blogging application. In blog.models we have:

class PublishedManager(Manager):
    def get_query_set(self):
        queryset = super(PublishedManager, self).get_query_set()
        return queryset.filter(pub_date__lte=datetime.now)

class Entry(models.Model):
    ...
    pub_date = models.DateTimeField()

    published = PublishedManager()
    ...

In blog.urls:

info_dict = {
    'queryset': Entry.published.all()
}
entry_list = url(
    regex  = '^$',
    view   = 'django.views.generic.list_detail.object_list',
    kwargs = dict(info_dict, paginate_by=10),
    name   = 'entry-list'
)

urlpatterns = patterns('', entry_list)

Internally, the generic view will _clone() the queryset sent in the info_dict, in order to get fresh data from the database. Unfortunately, at the time of the cloning, the queryset already has the filter applied with the datetime.now callable already invoked and the datetime value cached in the where clause. The generic view will always return the entries that have the pub_date less then or equal to the time when blog.urls module was loaded.

The work-around for this issue is to stop passing the queryset to the generic view through the info_dict dictionary. We can do that by creating our own view:

def entry_list(request, page=0):
    return django.views.generic.list_detail.object_list(
        request,
        queryset = Entry.published.all(),
        paginate_by = 10,
        page = page
    )

This way every time the view is called a new queryset will be created. This new queryset will always have in the where clause the current datetime.

Posted on August 16, 2008


Next Entries


Copyright © 2008 Mihail Ovidiu Pascut