Supply chain issues, the war in Ukraine and other factors have fueled shortages and price hikes in everything from sugar and pasta to beer and butter.