- Feature Articles
- CodeSOD
- Error'd
- Forums
-
Other Articles
- Random Article
- Other Series
- Alex's Soapbox
- Announcements
- Best of…
- Best of Email
- Best of the Sidebar
- Bring Your Own Code
- Coded Smorgasbord
- Mandatory Fun Day
- Off Topic
- Representative Line
- News Roundup
- Editor's Soapbox
- Software on the Rocks
- Souvenir Potpourri
- Sponsor Post
- Tales from the Interview
- The Daily WTF: Live
- Virtudyne
Admin
kwargs, stringness and churn
Admin
Got you beat there, Remy. I've been programming for over 10 years and have never thought about it until now
Admin
The Bridge to the River Kwargs?
Admin
True fact: kwargs is a yet to be discovered particle behind dark matter.
Admin
Well maybe if it would get out from behind there someone would discover it.
Admin
Have you considered that it might not want to be discovered?
Admin
Since class names are typically named as nouns, when I see one named 'Lead' I immediately think of the metal with atomic number 82, since the other common word 'lead' is a verb. But I have no idea what this specific metal has to do with filtering arguments. So it is probably something more domain-specific. Like sales leads or maybe horse leads. Those are both also nouns.
So TRWTF isn't Python, or even PHP. TRWTF is English.
Admin
If you read so much that you're well-read, you'll have the background which allows you to lead, instead of being lead.
I assume this is about sales leads.
Admin
If the method "set_filters_to_query" popped "view_by", this would also lead to some funny side effects
Admin
I accept that that elegance is often sacrificed to bolt misshapen things together, but
set_filters_to_query()
is the kind of dictionary comprehension taught in even the laziest intro boot camps.Admin
Ahhhh I can breathe again...
Admin
So kwargs isn't a Klingon commander?
Admin
I see what you did there
Admin
I thought he owned the bar on DS9?
Admin
No, he tended bar on DS9
Admin
If it was a Kilingon commander, then the function would be: set_phasers_to_kill();
Admin
And the news industry uses both terms. Lead as in the soft metal used for typesetting, and lead, as the main point of the story. It's not always obvious from context which one they mean. They got around this by having the second sense spelled as lede, so you can often see "burying the lead" as "burying the lede". That way lead referred to the element, and lede to the point of an article.
Admin
Sometimes, 'Lead engineer' is just a fancy job title for a plumber.
Admin
It's actually "lede" when referring to the main point of the story -- check out "burying the lede".
Admin
Kwarg them... with the soft cushions!
Admin
Klingons don't use phasers. The Federation uses phasers, mostly set to stun. Klingons use disrupters because they don't need any setting but kill.
Admin
And Led Zeppelin mis-spelled the name of the metal in their name, I guess because they didn't trust their fans to get the joke and pronounce "lead" as "led" rather than "leed".
Admin
As plumber is a named derived from Plumbum which is lead. Unfortunate this did not lead to the profession to be called leader
Admin
oh, this took me WAY back. back when i had an Apple II, i tried to write a simple game. i tried to use a variable called "score". BUT "or" is a protected word. BUT instead of simply telling me that, the silly computer kept mis-reading it as "sc OR e"! what a pain THAT was to debug.