It would also be easy for them to just break the extraction code. The old code used to break every time the signature function changed, and while the current code solves that problem, there are still so many things that they could do to break it, and yet they don't (the current code has only broken a few times that I can think of, and I don't think any of those were intentional on Google's part).
Technically it could violate these parts of the ToS, but they're all grey areas:
- access through anything than the site or 'approved' clients (but youtube-dl does use the site, so it could just be classed as another user agent)
- running automated services against them (running youtube-dl manually is probably fine, even for whole playlists or channels, but running a 'youtube-dl as a service' site like the one in this case is almost certainly not)
- downloading videos (but youtube-dl can also be used for streaming, despite the name)
I'm guessing that Google simply doesn't give a shit, as long as you're not using using it abusively (e.g. offering it as a service or using it to do mass-scraping).
In practice, they could combat the practicality by various methods, like embedding the ads in the video stream, throttling the stream to hurt the use-case of downloading vs watching (they already do this I think).
Ultimately YouTube could start properly DRM-ing all their streams. If you watch a film you've bought from Google Play via YouTube it is protected by Widevine DRM, and youtube-dl fails.
It seems like YouTube feel it's cheaper at the moment to try and frustrate downloading this way, but if they ever feel like it's a lost cause they'll just pull the Widevine lever.
I guess it's kinda surprising to me that it still works after all this time, that there isn't some sort of authentication involved to prevent it.