Pythonic Nirvana - towards a true Object Oriented Environment [visionary rambling, long]

Ville Vainio ville at spammers.com
Fri Jul 2 07:06:20 EDT 2004


>>>>> "Steve" == Steve  <dippyd at yahoo.com.au> writes:

    Steve> Ville Vainio wrote:
    >> Why do we write simple scripts to do simple things?

    Steve> Because building complicated programs to do simple things
    Steve> is a bad idea?

Of course, the idea is to write even simpler *functions* to do the
things. Even a simple script is much more complex than a simple
function that can access the data directly.


    >> Why do we serialize data to flat text files
    >> in order to process them?

    Steve> Because it is a tried and tested method that works?

I guess so was using flintstone to set up a fire :).

    Steve> Because flat text files are human readable, which is a huge
    Steve> advantage in the real world? (Just contrast the voodoo of

But so is a pretty-printed python data structure. Flat text file
breaks up as a solution when the data is not flat anymore. 

    Steve> More powerful, maybe. Simpler, no. A Python script might be
    Steve> simpler than the equivalent assembly code that does the
    Steve> same thing, but when you include the complexity of the
    Steve> Python framework vs the assembler, it is far more complex.

Isn't the general idea to shift complexity away from users to the
things written by "someone else"?

    Steve> Which *might* very well mean more OS bugs, hacks and
    Steve> cracks. Exploits in your script will only affect you;
    Steve> exploits in the OS will affect everyone. The comparison
    Steve> between Windows and Linux is so obvious that you should
    Steve> already be thinking it :-)

Needless replication of the code in the name of diversifying the
system (and therefore improving the security through
security-through-not-being-worthy-of-cracking) is really not the
optimal path IMHO. Common frameworks and shared code are still
fundamentally good things. Paranoid users just need to validate the
data they are about to process, as always.

I'll readily admit that highly integrated system would make it easy to
implement some very sneaky trojans that log the data flow of other
users (if they share the code). However, once you allow malicious code
to be installed on your hard disk, you are screwed anyway.

And as far the OS-ness goes - kernel and all the command line programs
could (and should) stay. It's the user-interaction stuff like shell
and GUIs that would benefit from the integration. Think of the
functionality like am extra gear that you can switch to when you would
otherwise implement non-trivial shell pipelines or a proper python
script.

-- 
Ville Vainio   http://tinyurl.com/2prnb



More information about the Python-list mailing list