When we were house training Sully as a puppy, he was confined in his kennel whenever we left the house - which was a lot. Not a cruel amount, but a lot.
Once he was pretty trained, we would "confine" him to the bathroom whenever we were gone so maybe about 3 hrs a day.
Now that Sully has zero accidents, and he runs free 24-7. Well, in the house or the studio or wherever we are