Remove query dependency on the 0.7 branch