Fix address encoding issues the same way Django handles encoding addresses