I never have in maybe half a dozen times, but if I and more people did it would happen less. I believe the consequences to the driver are quite steep. Usually if you are refused and not in the cab yet the driver won't stick around for you to get a good look at the plate/medallion/driver info. Another anecdote: I had a cab passenger open their door into my car once and while chatting with said passenger the driver (who saw what had happened) sped off as soon as the door was shut.
Different country, I'm in Australia, but I've reported many cabs for breaking various rules (and laws) as well as being outright hostile. I have an intense dislike of our cab duopoly in Brisbane, but to both of the companies' credit, they appreciated the heads-up when it came to dangerous, rude or illegal drivers. I highly recommend others report cabbies who break the rules, as if we don't they will never improve.