How can I troubleshoot why my queue of tasks in stuck in Craft 3?
I typically just truncate (delete all of the rows) the queue table if something goes wrong with a task.

Then I delete all of the files in storage/logs/ and I try to reproduce the problem. If it still happens, then I look in queue.log and web.log to see what the issue is.

Usually searching on [error] finds what I'm looking for pretty easily. Occasionally I have to browse through the file to find the actual problem, but that's why I delete the log files before I do it, so there isn't as much to wade through.

Relevant articles I wrote since this answer:


Robust queue job handling in Craft CMS
Zen and the Art of Craft CMS Log File Reading