Why does the Ubuntu Software application think I am offline when I am online for all other applications and services?

This turned out to be a bug in Snap and Ubuntu Software. I reported it here. I am sure it will be fixed soon.