I recently encountered a problem on my freebsd postfix mail server with the packet py27-postfix-policyd-spf-python-1.3.2_1
My maillogs where full with the following messages:
policyd-spf[16637]: ERROR: 127.0.0.0/8 in skip_addresses not IP network. Message: '11.22.33.44' does not appear to be an IPv4 or IPv6 address. Did you pass in a bytes (str in Python 2) instead of a unicode object?. Aborting white list processing.
Switching to python 3 as suggested by other people did NOT work (neither changing the shebang, nor starting it via python3 directly