make get_lock use a lua script