It's always a judgement call. The code doesn't say "ball/racquet hits person, it's an automatic default" (although many spectators and even tennis commentators seem to be believe so).
This comes up every time a player hits or almost hits someone... But it's up to the umpire/referee. If you go and shapovalov someone, then yeah, it should be a DQ on the spot. But if that ball Fed hit happened to touch someone? Nah.
The warning (and subsequent point penalty) here were excessive. And I don't even like Fed
Default is always discretionary.
There is slack in the "Ball Abuse" rule as well and it was a very strict read of the rule to penalize FEDR here, IMO:
"i) Players shall not violently, dangerously or with anger hit, kick or throw a tennis ball while on the grounds of the tournament site except in the reasonable pursuit of a point during a match (including warm-up). For purposes of this rule, abuse of balls is defined as intentionally or recklessly hitting a ball out of the enclosure of the court, hitting a ball dangerously or recklessly within the court or hitting a ball with disregard of the consequences. ii) Violation of this section shall subject a player to a fine of up to $350 for each violation. In addition, if such violation occurs during a match, the player shall be penalized in accordance with the Point Penalty Schedule."
As you stated it's The Supervisor not the The Chair that can default a player during a match "either for a single violation of the Code (immediate default) or as outlined in the Point Penalty Schedule." This explains why The Supervisor (aka referee) comes out to the court to confer with The Chair before a player default.
PS, some tennis commentators don't know anything about the rules of tennis. It's not a requirement for the job.