> people who don't have much free time: people with responsibilities to look after young children or otherwise care for family
Maybe that's the entire purpose. You don't want to hire people with small kids, because they won't do much of an overtime. But asking people at an interview whether they have kids, and firing them after they say yes, that's legally dangerous. So instead you ask them if they spend a lot of time doing their hobbies, and fire them if they say no. Perfectly legal.
More cynically, if this becomes the norm, even the people who don't enjoy programming in their free time will start coding their "hobby" projects for github, just to be able to get a job. Is that a bad thing (for the employer)? No, that's actually a good thing: it demonstrates willingness to spend your free time doing what the employer requires of you, even before they start paying you. Now that's a model employee!
Maybe that's the entire purpose. You don't want to hire people with small kids, because they won't do much of an overtime. But asking people at an interview whether they have kids, and firing them after they say yes, that's legally dangerous. So instead you ask them if they spend a lot of time doing their hobbies, and fire them if they say no. Perfectly legal.
More cynically, if this becomes the norm, even the people who don't enjoy programming in their free time will start coding their "hobby" projects for github, just to be able to get a job. Is that a bad thing (for the employer)? No, that's actually a good thing: it demonstrates willingness to spend your free time doing what the employer requires of you, even before they start paying you. Now that's a model employee!