improved sparql.py unicode handling