Is it illegal to collect shopping receipts discarded by others and open personal invoices to participate in the government-run invoice lottery?

I don't think it's illegal. Since being abandoned, it means that this person doesn't want it at all and doesn't need it. Whether you take it to invoice or participate in the lucky draw, it is your freedom, and winning the prize is also your luck. Of course, if you really win the lottery and know whose receipt it is, it is ok to give you a small gift or invite you to dinner. At least you can feel at ease.