Fix the ipaddress deprecation error

As title