Okay, lets take this argument in a different direction. Instead of chickens, lets say you are making really cute hair bows. Lets say you are really good at making them and everyone always compliments your kids hair. They want to have you make a hair bow for them. Then you decide that you want to "go into buisiness" and you go to the craft store, buy 3 rolls of ribbon and some clips and a couple hours later you have a cute little Etsy shop. You stick a small package in the mailbox twice a week when you sell something. Great, right? Well, what if your HOA or community said that it was zoned residential, not commercial? My guess is that 99 percent of people wouldnt care or even think twice about selling your hair bows on etsy. They might care if you decided to ramp up production. Maybe they would care if you had 150 illegal workers coming in your house everyday to run a ribbon making sweatshop. They might care if you started using hazardous glue by the barrel and left the barrels out in your yard. They might care if you had large trucks coming every hour to deliver supplies or take hairbows. But that is ridiculous. I think we would all agree there is a BIG difference between the two scenerios.
Raising 3 hens in your backyard for eggs for your family and a tomato plant in a pot on your porch is ENTIRELY different than having a turkey farm raising/slaughtering/breeding thousands of turkeys. 3 hens are VERY quiet. They are much quieter than a dog. So, I would say the law is there to keep problems out. But if you are responsible and cause no damage / irritation to your neighbors, then its not a problem. There is a difference between illegal and immoral.
Also. You can break the law. Just be prepared to live with the consequences. If you have chickens, you might have to rehome them. If you speed you could get a ticket- or kill a child. Etc. So, before you do something, think through the consequences. Is it something you are willing to deal with? Depends. Our old HOA required permits to plant anything in your front yard. Honestly, I didnt ask permission before I planted some marigolds in a pot on my front porch. If I had to move them I would. However, if I were to add an addition on to my house... I would get a permit. The consequence of tearing THAT down would be more than I would be willing to risk. Life is rarely completely black or white. The joy comes from all the colors inbetween.