What is mediapartners and what are they doing with the data they've fetched? You can block any bots from accessing your site, any it's your site. Unless you have agreement with mediapartners, regarding that, it should be fine.
You're free to block whatever bot you want from your site. The only thing that I can see being bad about it, the fact that you wouldn't show on other sites that have adsense code on their site. So you are potentially losing customers. Now, if you have a site that is displaying adsense ads, then you might be violating TOS, go back and read the terms that you agreed to. I can almost guarantee that if you had read them when you signed up, you wouldn't be asking this question.
Thank you for your answer sir but there is no such thing mentioned in google adsense tos I have read the whole content 3 times you can check for your self do you think it is still dangerous to do so