other misc modules: type(X) is Y ==> isinstance(X, Y)
Merge pull request #14527 from hulu/use-isinstance-more-misc

other misc modules: type(X) is Y ==> isinstance(X, Y)