I dislike this take, for many reasons.
1. Software development isn't some magic field that is different from anything else. People do it mostly because it's good money. Sure, some genuinely enjoy it, but almost no one would do the kind of work they do full time if they weren't getting paid well.
2. Even people who start off with a "love of the craft",so to speak, are usually doing it "for the money" after 5, 10, 20 years.
3. People might not realize whether or not they enjoy coding without trying. Filtering people before they even start because they don't realize whether they like it or not is not a good idea.
4. Most importantly, people are the judge of their own lives. Development might be hard (though arguably a easier than other fields), but people can decide for themselves whether, given their current circumstances, it's worth the hard work in order to earn more money.