>Anything that reduces competition in the marketplace is bad for society as a whole
Just like engineering, every economic design has tradeoffs. There's no ideal solution to the problem, and if there is it certainly isn't unbridled competition.
Labor protections have to exist in order to humanize the commodity that it is, especially when demand dips below supply. Otherwise labor will be exploited. The difference between labor and oil as a commodity is that labor is people with unalienable rights. Unlimited and unregulated competition cannot always guarantee those rights, it can infringe on them for no fault of the individuals affected.
That's why there can never be a truly free market for labor that is also moral - all the upsides of the S/D curve are mirrored by the downsides. Competition is amoral; it's neither innately good or bad for society. The effects of competition can be good, which we should encourage, but they can also be quite negative, which is why we need consumer and labor protection.
For developers in all industries, I see major upsides to unionization. It's not synonymous with reduced competition or salary schedules. Think more in terms of minimum salaries, work and vacation schedules, healthcare/pension funding that isn't tied to your employer, standardized NDA and non-competes, standard FOSS contribution policies.
And yea, I think a lot of us in a hypothetical union would want to codify stuff like a meritocracy and salary/equity negotiations. People on the whole are reasonable. The idea of a union is not to ruin competition for developers, but to provide some benefits developers who don't work at the top of the game for the biggest companies out there. There's a lot of bullshit people at small and mid sized shops deal with that we could fix if we unionized.