Beefy Boxes and Bandwidth Generously Provided by pair Networks
go ahead... be a heretic
 
PerlMonks  

comment on

( [id://3333]=superdoc: print w/replies, xml ) Need Help??

(apologies for mistakes; I have to leave in a hurry and re-read atm.)

Based on the replies so far, this post isn't going to get very many upvotes. But: ferrency's points strike me as sounding good on the surface, but really counter productive and pretty much impossible to actually follow.

Blatantly obvious isn't, in the chatterbox. The person reading your chats or posts might not understand you're kidding.

So, what are you saying here? Label all jokes as *** JOKE ***? Don't make any jokes at all? Make sure that all your jokes are clean, healthy, and couldn't possibly cause anyone any damage? (Is that possible?)

If you post code, there's always a chance, no matter how small, that someone will run it. As root. On a production server. At 5pm on a Friday afternoon before a long weekend, when you're manning the pager.

Right! Of course there is! In fact, it's probably the reason you've got a pager in the first place - because there's a high likelihood that at some point in the future, someone is going to mess up and break things.

So don't post coode that you don't want people to run, even if it's completely obvious that you don't want people to run it (see #1).

What, don't post code that shouldn't be run even as an example? Or as a joke? What about if someone says "what would be a bad way to do this?"? Because even then there's a chance that, say, someone will only catch the last half of the conversation and misinterpret things. Does that mean the conversation shouldn't have happened in the first place?

Don't run code that you don't understand.

Does that include modules? Code you're trying to debug? Do you mean just perl, or any language? Should you avoid running code you don't understand when trying to learn perl? What about compiled code?

This can be a bit tricky when obfuscation is involved.

From Webster's Revised Unabridged Dictionary (1913) :

Obfuscate \Ob*fus"cate\, v. t. [imp. & p. p. Obfuscated; p. pr. & vb. n. Obfuscating.] To darken; to obscure; to becloud; hence, to confuse; to bewilder.

Any code that you don't understand - code that confuses or bewilders you - is obfuscated by definition. I'm sure you meant intentionally obfuscated, but does it make much difference to the beclouded user?

There is a valid side to your points, though: basically, "be careful". But being careful should mean expecting errors and being prepared for them: setting yourself up in a safe environment where it's OK to break things - in fact, where breaking things is good, because you'll hopefully learn something in the process. Trying to ensure everything you do and say is foolproof, even at the cost of humour and the possibility of learning through trial and error, is the wrong way to go about things.

Besides, your example wouldn't have worked. rm would have balked at the -c. And even if it had worked, aren't you already breaking your first two rules? :)


In reply to Re: "Don't try this at home" by Anonymous Monk
in thread "Don't try this at home" by ferrency

Title:
Use:  <p> text here (a paragraph) </p>
and:  <code> code here </code>
to format your post; it's "PerlMonks-approved HTML":



  • Are you posting in the right place? Check out Where do I post X? to know for sure.
  • Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
    <code> <a> <b> <big> <blockquote> <br /> <dd> <dl> <dt> <em> <font> <h1> <h2> <h3> <h4> <h5> <h6> <hr /> <i> <li> <nbsp> <ol> <p> <small> <strike> <strong> <sub> <sup> <table> <td> <th> <tr> <tt> <u> <ul>
  • Snippets of code should be wrapped in <code> tags not <pre> tags. In fact, <pre> tags should generally be avoided. If they must be used, extreme care should be taken to ensure that their contents do not have long lines (<70 chars), in order to prevent horizontal scrolling (and possible janitor intervention).
  • Want more info? How to link or How to display code and escape characters are good places to start.
Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others having a coffee break in the Monastery: (7)
As of 2024-04-19 16:28 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found