I notoced that you use an dictionary to record those bodies, it looks like you may have more than one body, so you can use for loop to check all of them.
for body in items_in_range.values():
if body.is_in_group("NPCHH"):
print("blablabla")
# do what you want to do.