I also ran into this problem today with a Canon PIxma MG5420. I have not used the upper tray in ages, and botom tray has paper, but printer insists on trying to print from upper tray. Really annoying is that I went through all of the settings I could access from the printer itself, several times, and could find nothing about which tray to use.
Based on another post in this thread, I repeated the process of printing the desired web page. But this time, I dug into whatever print settings I could find from the print page, and likely found the cupprit. It's probably Google Chrome. Or possibly AWS.
I was trying to print a report from the Amazon Web Services site while using Chrome. On the page was a "Print" button. That brings up a popup window of printer settings. Then had to click the link with label "More settings", which brings up a setting for "Paper size". This was set to "4 x 6". When I changed that to "Letter", and clicked the "Print" button, the page printed with no problem. So apparently, because this was set to "4 x 6", some logic somewhere decided the printer needed to use the upper tray and not the lower tray. I do not know any good reason why the value "4 x 6" was selected for paper size. I have not selected that size. And with that setting, it wanted to print 2 pages, so it does not seem like a case of "what needs to be printed will fit in 4 x 6 box".
I don't know if it's Chrome or the AWS website that caused the erroneous Paper size of "4 x 6". Though it does seem as if the Canon software ought to give better clues as to what is going on and provide a way to specify the correct paper tray.