There are 2 system in drupal 7 for IP blocking, one is flood blocking that is used on login and other is
system_block_ip_action that is storing IP's in blocked_ips table and checking them while bootstrapping.
If you use the second one and maybe you are running some tests, you could get your test broken and getting 403 as bot will be blocked by this, solution for this is to put this in settings.php so this will override anything that is saved in DB table
$conf['blocked_ips'] = [];