One question: is it OK that `query_sequence` has whitespace inside? If not, you could use implicit string concatenation like we did in the exception.

Same question for the following line.