Check your sampling. Thinking tends to loop with temperature too low or zero. It was designed to run with temp = 1, top_k = 20, top_p = 0.95.
Also, default thinking effort is xhigh. Try setting reasoning_effort = medium.
That should be good for many tasks where high is not needed.
I found this guide helpful: https://prompt-architects.com/blog/315-how-to-prompt-qwen-mo...