correctly decode entities even on narrow Python build