A lambda function is just an anonymous function (i.e., one you define in place without naming it). The common_filter does not have to be a lambda function -- it can be any callable object that takes a single argument and returns a Query object. So, you could do:
def my_common_filter(query):
return db.blog_post.is_public == True
db.blog_post._common_filter = my_common_filter
When the common filter function is called, the current query will be passed to it. In the above example, that query argument is ignored, but in theory, you could inspect that query argument and have the return value depend on it somehow. The final query will end up being a conjunction of the original query and the return value of the common filter function.
Also, note that the argument of the common filter function (whether a lambda function or otherwise) does not have to be "query" -- that is just a convention to remind you that the original query will be passed into the function. You can name that argument whatever you want.
Anthony