Guido van Rossum <gu...@python.org>: > With my serious hat on, I would like to claim that *conceptually* > filenames are most definitely text. Due to various historical > accidents the UNIX system calls often encoded text as arguments, and > we sometimes need to control that encoding.
Due to historical accidents, text (in the Python sense) is not a first-class data type in Unix. Text, machine language, XML, Python etc are interpretations of bytes. Bytes are the first-class data type recognized by the kernel. That reality cannot be wished away. > Hence the occasional need for bytes arguments. But most of the time > you don't have to think about that, and forcing users to worry about > it is mostly as counter-productive as forcing to think about the > encoding of every text file. The users of Python programs can often be given higher-level facades. Unix programmers, though, shouldn't be shielded from bytes. Marko _______________________________________________ Python-Dev mailing list Python-Dev@python.org https://mail.python.org/mailman/listinfo/python-dev Unsubscribe: https://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com