Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Simplicity vs. Doing It Right

by Revelation (Deacon)
on Oct 13, 2002 at 04:12 UTC ( [id://204856]=note: print w/replies, xml ) Need Help??


in reply to Simplicity vs. Doing It Right

But many of us are inclined to do thing right. We know that today's requirements are incomplete and will probably grow anyway, and that we'd better plan for the future by building solider solutions than are asked for, leveraging tested, off-the-shelf code where possible to save effort.

"The right way" to me is based more often for the situation I'm using my code in than basic programming advice given to me. If a user says "I don't have access to module X, I'm not going to tell them 'use module X', or ask 'why can't you use it', but instead try to give them a possible solution. The advice of using modules is helpful, if the person intends to use modules, but I find it more important to have a viable solution.

The conventions of cpan, and of a dbm are there to perl easier to use. However, the zealous 'use module X', and 'don't roll your own' point out another use of modules: to impel users to refractor their code. This is only helpful when a user is programming with the intent to find the best solution! Most perl-monks write code built for programmers, instead of code built for basic distribution to the perl-illiterate masses.

Why use mySQL, when you don't have access to it? Or when a simple flat file system will suffice? Why force your users to download tons of modules, when you can incorporate your own code? It's interesting to observe that many web-hosting companies now offer 'developer packages', specifically designed to allow for these conventions. (Hard linked perl libs, pseudo-root access, access to the apache binaries.)

Sometimes facing reality, and understanding that if you're making a widely distributed package, your users may not have the same access to modules, or programming abilities as you is necessary. All web hosting companies aren't up to allowing mySQL access, and not everybody is smart enough to understand the conventions of use lib; or @INC. If you orient your code towards them, the best solution may very well be unconventional means. (an example of this is a package I'm creating that dynamically loads tons of modules, and even assigns to @ISA, so that users will have very little to deal with, when using it.)

You'll find a lot of widely used software makes similar amenities to users; catering to an Aristotelian sense of the lesser of two evils, by sacrificing conventions for ease of use for the average Joe. Is that bad or good? I don't know.

Gyan Kapur
gyan.kapur@rhhllp.com

Replies are listed 'Best First'.
Re^2: Simplicity vs. Doing It Right
by Anonymous Monk on Jun 27, 2005 at 22:54 UTC
    "...catering to an Aristotelian sense...is that bad or good? I don't know." It's good. Too often people underestimate the values of user-friendliness and assume that it is always necessary to be conventional. Besides, Aristotle has taught me very well. -Asymptotic Freedom

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://204856]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others avoiding work at the Monastery: (4)
As of 2024-03-29 05:02 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found