Robert Morris wrote Viaweb's shopping cart. He is a smart programmer, and he found it nontrivial. Years later he was still encountering bugs from weird combinations of user actions.
Dell finds it nontrivial as well. I just used their shopping cart. At one point it wiped out the entire contents of my cart when I added an item from a different section.