Risk and ethics are 2 different things.
In the opinion of some it is unethical to purchase from a puppy mill or pet store because of how the dogs are bred or where they come from. Which people call inhumane housing, some can be really horrible. You are directly supporting them by doing this. There is certainly a risk, you could end up with a that has no problems or they could have many problems.
If you go to a rescue it is considered good because you are saving a dog and not directly supporting a mill/pet shop. Even if the pup/dog came from a mill/pet shop. If they come from mill raids, are turned over by the original purchaser, ect, ect then there is no questions of ethics. It would not at all be unethical to rescue a dog from this background. But yes of course the same risk are there. Whether you go to the pet shop or to the shelter/rescue and get a mill dog.
If they are purchasing from mills and the mill auctions like some rescues are doing then that is not ethical IMO. They say they want to save those dogs from becoming breeders and bringing in more, but they are keeping the cycle going. Just as much as if you yourself bought from there. Which is where the irony lies. When someone buys from a mill/auction they are considered to have done a bad thing and supported the mill, even if the person looks at it as rescuing the pup from a possible future of a bad life. While those pups might not grow up to become breeders and won't be bought by mills, the mill will still buy another dog for their purpose. The rescues can't buy them all. But what I've found it like you said some use them as fundraisers basically. There is also the fact that not all private rescues are non profit and basically they are not using this excess of money to go back into the rescue, but for themselves. They are pretty much like the pet shop themselves. They buy from the auction to "rescue" the pups and then sell "adopt" them to knew homes.
One would rescue a dog from a mill/pet store because that is different. If the dog wasn't obtained through the rescue purchasing. It would not be unethical.
There are genetic and environmental factors that could lead to getting a dog with a lot of problems. It doesn't mean all of them will have problems though.
You also asked/state
Do I risk it? Why would they?
It is up to you what risk you want to take. But the fact is going to a rescue and getting any dog period is a risk. In this case you are talking about dogs bought from mills/pet shops. But with many dogs in rescues their background is not always known. If you go to adopt other dogs where do you think they came from? They could have come from a mill, a dog that someone bought from a pet shop and no longer desired. They could have come from a neglect case where they were kept in poor conditions. They could have come from an oops litter (which doesn't always guarantee better genetic health over a mill dog). They could have been a pup from a litter a dam that was very neglected during pregnancy and after whelping, with no known genetic health history either. Even if you yourself take a stray off the street there is great chances it came from a byb, mill or oops litter. Sometimes dogs from good pedigree do end up in rescues too, but the numbers are probably very low that you are more likely to get one that originally started out in a bad source.
The reason why they take the risk is because these dogs need homes. If there were not pups/dogs coming from mills, byb and oops litters then there would more then likely not be a need for a rescue in the first place.
I want a healthy puppy that will be with us for a long time.
There is really no guarantee with a living animal. There isn't a guarantee with a rescue dog whether they are bought from a mill or not. Like I also said above you can't always know either. Even if they didn't come directly from a mill to the rescue they could have been a mill dog. More then likely they are a dog from a bad to a decent background without much way to find out one way or another.
Many adopted dogs do live long happy lives, some with no to minimal health problems. Others do however develop issues.
The best chances of getting a pup who will live a full healthy life is from a reputable breeder. Even then there is no guarantee 100%. There is just more known about their pedigree history and what the line produces health wise.