Unfortunately (or is it) the Constitution Of the United States, and the laws that follow, are intended to keep us from violating the rights of others as it prevents them from violating our rights, laws were not supposed to pad the world around us to the point we are put into a padded cell. if it did then there are allot of dangerous sports, jobs, and hobbies we all enjoy that would become outlawed.
Many States have laws that protect the rights of home owners, who wish to take the chance to do their own work, these are called log cabin laws.
Also I saw some responses to report hazards like this to inspectors, well since they are law enforcement, they need a probable cause before they can trespass upon private property, they just cant just run out there and start citing violations from hearsay, another thing our Constitution protects us from.
Yes many of these rights are being taken from us little by little, and maybe some day we will all live in a totally padded world, But for now, I'm glad we don't.
With that said, if I were to come upon a hazard like this( And I have many times), I would tell the home owner if he wanted me to touch anything on this property, I would have to fix any hazards as I could be liable for them if I work on it, if not he would have to get another electrican. It's that simple. you can't be held liable just for knowing and the owner refusing to allow you to fix it. but if you touch the wiring then it can be a different story.