Handle unicode input; for non-unicode input, accept encoding="...",