o describe their behaviour.
--
\ “One bad programmer can easily create two new jobs a year. |
`\ Hiring more bad programmers will just increase our perceived |
_o__) need for them.” —David Lorge Parnas, 1999-03 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
n no way diminishes it, it is not rightly |
`\ owned if it is not shared.” —Saint Augustine |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
e. Thanks for caring enough about this community to act in the
interest of keeping it open, considerate, and respectful.
--
\ “Beware of and eschew pompous prolixity.” —Charles A. Beardsley |
`\ |
_o__)
in |
`\ only ten minutes.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
_Following the Equator_ |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ly FAX |
`\ collect.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
—Niels Bohr |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ion that behaves the way you'd expect it to behave, and
we can explain either how to achieve that or why it can't.
--
\ Q: “I've heard that Linux causes cancer...” Torvalds: “That's a |
`\ filthy lie. Besides, it was only in rats and has not been |
_o__)
ect the other fellow's religion, but only in the |
`\ sense and to the extent that we respect his theory that his |
_o__) wife is beautiful and his children smart.” —Henry L. Mencken |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
st/grimace and the first blog
post that explains it is here: http://benlast.livejournal.com/30871.html (I've
added to it since then).
Tests are the best explanation, and they're in the __init__ at the end so
that they're self-executing if the init is executed.
I'm thinking about other features to i
On 16 July 2013 20:48, wrote:
> From: "Anders J. Munch" <2...@jmunch.dk>
> Date: Tue, 16 Jul 2013 13:38:35 +0200
> Ben Last wrote:
>
>> north_american_number_re = (RE().start
>> .literal('(
> From: Gregory Ewing
> To: python-list@python.org
> Is 'dash' the same as 'literal("-")'?
>
Yes, it's a convenience method, like 'dot' and 'underscore'. The code I
pasted is from the unit tests, where I use the different methods to push
coverage up.
> Is there any difference between 'then' and
cutems93 writes:
> I am currently doing some research on testing software for Python. I
> found that there are many different types of testing tools. These are
> what I've found.
You will find these discussed at the Python Testing Tools Taxonomy
http://wiki.python.org/moin/PythonTestingToolsTaxo
xclusively human concern with no |
_o__) superhuman authority behind it.” —Albert Einstein, letter, 1953 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ng the above library.
--
\ “True greatness is measured by how much freedom you give to |
`\ others, not by how much you can coerce others to do what you |
_o__) want.” —Larry Wall |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
cutems93 writes:
> On Saturday, July 20, 2013 1:11:12 AM UTC-7, Ben Finney wrote:
> > You will find these discussed at the Python Testing Tools Taxonomy
> > http://wiki.python.org/moin/PythonTestingToolsTaxonomy>.
> >
> > Hope that helps.
>
> Thank you, b
prayer.” —Anonymous |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
the kid next door's imaginary friend.” —Emo Philips |
`\ |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
le's shebang line.
--
\ “When cryptography is outlawed, bayl bhgynjf jvyy unir |
`\ cevinpl.” —Anonymous |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
his forum.
--
\“Pinky, are you pondering what I'm pondering?” “Wuh, I think |
`\ so, Brain, but wouldn't anything lose its flavor on the bedpost |
_o__) overnight?” —_Pinky and The Brain_ |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
t purpose.
--
\ “There is something wonderful in seeing a wrong-headed majority |
`\ assailed by truth.” —John Kenneth Galbraith, 1989-07-28 |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
se keep this a text-only forum.
--
\ “Come on Milhouse, there’s no such thing as a soul! It’s just |
`\ something they made up to scare kids, like the Boogie Man or |
_o__) Michael Jackson.” —Bart, _The Simpsons_ |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
to invent it.” —Alan Kay |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ed with those symbols. Expecting that any
symbol, before Python defines it, will be devoid of any normal meaning
is a delusion.
--
\ “The Vatican is not a state.… a state must have territory. This |
`\ is a palace with gardens, about as big as an average golf |
_o__)
Chris Angelico writes:
> On Sun, Jul 1, 2012 at 10:08 AM, Ben Finney
> wrote:
> > Thomas Jollans writes:
> >
> >> My sole point, really, is that "normally", one would expect these two
> >> expressions to be equivalent:
> >>
> >
\ “Pinky, are you pondering what I'm pondering?” “Uh, I think so, |
`\ Brain, but we'll never get a monkey to use dental floss.” |
_o__) —_Pinky and The Brain_ |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
Harris, _The End of Faith_, 2004 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
versions of Python with ‘unittest2’
http://pypi.python.org/pypi/unittest2>.
--
\ “I prayed for twenty years but received no answer until I |
`\ prayed with my legs.” —Frederick Douglass, escaped slave |
_o__)
ions to conform themselves |
`\ to fact, not to try and make facts harmonise with my |
_o__) aspirations.“ —Thomas Henry Huxley, 1860-09-23 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
month?
--
\ “Earth gets its price for what Earth gives us.” —James Russell |
`\Lowell |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
atch?v=jG7vhMMXagQ>
--
\ “Why am I an atheist? I ask you: Why is anybody not an atheist? |
`\ Everyone starts out being an atheist.” —Andy Rooney, _Boston |
_o__)Globe_ 1982-05-30 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
need a book of any description to help you have some |
`\kind of moral awareness.” —Dr. Francesca Stavrakoloulou, bible |
_o__) scholar, 2011-05-08 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
#x27;t need to worry about text
editors again.
--
\“All opinions are not equal. Some are a very great deal more |
`\ robust, sophisticated, and well supported in logic and argument |
_o__) than others.” —Douglas Adams |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
--
\ “The way to build large Python applications is to componentize |
`\ and loosely-couple the hell out of everything.” —Aahz |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ng over the awe of ignorance |
`\ any day.” —Douglas Adams |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
but if not then you thereby exclude yourself.
--
\ “You can stand tall without standing on someone. You can be a |
`\ victor without having victims.” —Harriet Woods, 1927–2007 |
_o__) |
Ben Finney
--
http://mail
`\ but if you really make them think, they'll hate you.” —Donald |
_o__) Robert Perry Marquis |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
d, modular design.
And when the real domain to be modelled almost certainly has people as a
central entity in complex interactions, removing Person from the design
entirely is poor work grounded in irrationality.
--
\ “I am amazed, O Wall, that you have not collapsed and fallen, |
`\since you must bear the tedious stupidities of so many |
_o__) scrawlers.” —anonymous graffiti, Pompeii, 79 CE |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
#x27;ve discovered this, and apply it well :-)
--
\ “See, in my line of work you gotta keep repeating things over |
`\ and over and over again, for the truth to sink in; to kinda |
_o__) catapult the propaganda.” —George W. Bush, 2005-05 |
Ben Finney
--
http://mail
to be inviting
different confusion.
--
\ “I'm not a bad guy! I work hard, and I love my kids. So why |
`\ should I spend half my Sunday hearing about how I'm going to |
_o__) Hell?” —Homer Simpson |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
project that's still
going strong and meeting a specialised need with free software.
--
\ “I object to doing things that computers can do.” —Olin Shivers |
`\ |
_o__)
Xantipius writes:
> subj
resp
--
\ “What is needed is not the will to believe but the will to find |
`\ out, which is the exact opposite.” —Bertrand Russell, _Free |
_o__) Thought and Official Propaganda_, 1928 |
Ben Finney
--
http://mail.python.
\ “If you always want the latest and greatest, then you have to |
`\ buy a new iPod at least once a year.” —Steve Jobs, MSNBC |
_o__) interview 2006-05-25 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
open the account, after which the
full amount of the inheritance will be transferred.
--
\ “I may disagree with what you say, but I will defend to the |
`\death your right to mis-attribute this quote to Voltaire.” |
_o__) —Avram Grumer, rec.arts.sf.written,
ing that if they left |
`\ earlier they wouldn't have to go so fast.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
n quoted text.
https://en.wikipedia.org/wiki/Bracket#Square_brackets_.5B_.5D>
--
\ “What I resent is that the range of your vision should be the |
`\ limit of my action.” —Henry James |
_o__)
rk for Python.
--
\ “The best mind-altering drug is truth.” —Jane Wagner, via Lily |
`\ Tomlin |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ot replying http://brooksreview.net/2011/01/interleaved-email/>.
--
\ “We tend to scoff at the beliefs of the ancients. But we can't |
`\scoff at them personally, to their faces, and this is what |
_o__) annoys me.” —Jack Handey |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
information.
That's not a license for such behaviour, but an observation on its
effectiveness.
I'd say that so long as you phrase your assertions to indicate the level
of confidence and possibility of error, that's okay.
--
\ “Generally speaking, the errors in reli
hat we
require civil behaviour here, for anyone who may be watching but not
saying anything.
--
\ “Skepticism is the highest duty and blind faith the one |
`\ unpardonable sin.” —Thomas Henry Huxley, _Essays on |
_o__) Controversial Que
lipska the kat writes:
> On 23/08/12 14:59, Ben Finney wrote:
> > lipska the kat writes:
> >
> >> On 23/08/12 05:14, Steven D'Aprano wrote:
> >>> I think that's uncalled for.
> > […]
> >
> >> Excellent advice as usual, but I
Steven D'Aprano writes:
> No offence to Ben Finney, but I think sometimes he's a bit too eager
> to emphasise the subtle differences between Python and other
> languages, rather than the similarities.
No offense taken.
> Again, context is important:
Indeed. Note th
ng run, the utility of all non-Free software |
`\ approaches zero. All non-Free software is a dead end.” —Mark |
_o__)Pilgrim, 2006 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
mirror and got seven years bad luck, but my lawyer |
`\thinks he can get me five.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
you can coerce others to do what you |
_o__) want.” —Larry Wall |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
d library.
--
\ “If we don't believe in freedom of expression for people we |
`\ despise, we don't believe in it at all.” —Noam Chomsky, |
_o__) 1992-11-25 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
n |
`\ is, and then realise half of 'em are stupider than that.” |
_o__) —George Carlin, _Doin' It Again_, 1990 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
asses |
`\over generations, the truth will seem utterly preposterous and |
_o__)its speaker a raving lunatic.” —Dresden James |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
“Compulsory unification of opinion achieves only the unanimity |
`\of the graveyard.” —Justice Roberts in 319 U.S. 624 (1943) |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
nk you!
--
\“The problem with television is that the people must sit and |
`\keep their eyes glued on a screen: the average American family |
_o__) hasn't time for it.” —_The New York Times_, 1939 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
he module -- change file path, open for
> string I/O rather than file I/O, etc.
I don't know of any real-life code which would be significantly improved
by that. Can you point us to some?
--
\ “I find the whole business of religion profoundly interesting. |
`\ But it does mystif
Ben Finney writes:
> So, having written the opener:
>
> > On Mon, 03 Sep 2012 15:29:05 +0200, Christian Heimes wrote:
> > > import os
> > >
> > > def opener(file, flags):
> > > return os.open(file, flags | os.O_EXCL)
>
> why not c
more Pythonic, expose those numeric modes using strings:
>
> open(file, 'wx')
Which is, indeed, another improvement in Python 3.3 – the ‘x’ mode for
‘open’ http://docs.python.org/dev/library/functions.html#open>.
--
\“The greatest tragedy in mankind's entire hi
nt out *how* the original poster's question can
be improved.
--
\ “I think Western civilization is more enlightened precisely |
`\ because we have learned how to ignore our religious leaders.” |
_o__) —Bill Maher, 2003 |
Ben Finney
--
_Following the Equator_ |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
e man who is |
`\ able to think things out for himself, without regard to the |
_o__) prevailing superstitions and taboos.” —Henry L. Mencken |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
“First things first, but not necessarily in that order.” —The |
`\ Doctor, _Doctor Who_ |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
—Eugene P. Gallagher |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
is five hundred pages long.” —Chris |
_o__) Rodda, 2011-05-05 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
specifically.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
o those who are like us, we will squander |
`\ the great opportunity before us: To live together peacefully in |
_o__)a world of unresolved differences.” —David Weinberger |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
h control over, except to stop
using Google Groups.
--
\ “Actually I made up the term “object-oriented”, and I can tell |
`\you I did not have C++ in mind.” —Alan Kay, creator of |
_o__)Smalltalk, at OOPSLA 1997 |
Ben Finney
--
http://m
are any good, you'll have to ram them down people's throats.” |
_o__)—Howard Aiken |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
Howdy all,
Where can I find a standard implementation of the docstring parsing and
splitting algorithm from PEP 257?
PEP 257 describes a convention of structure and formatting for
docstrings http://www.python.org/dev/peps/pep-0257/>. Docstrings
that conform to this convention can therefore be pa
Joel Goldstick writes:
> On Tue, Sep 18, 2012 at 1:03 AM, Terry Reedy wrote:
> > On 9/17/2012 10:03 PM, Ben Finney wrote:
> >> Where can I find a standard implementation of the docstring parsing
> >> and splitting algorithm from PEP 257?
>
> Do you know abo
vulnerability if i don't know which
> one is it?
This is not the forum to discuss it.
--
\ “It is the fundamental duty of the citizen to resist and to |
`\ restrain the violence of the state.” —Noam Chomsky, 1971 |
_o__)
are my principles. If you don't like them I have |
`\others.” —Groucho Marx |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
text manipulation,
set the new value on the node. Re-serialise the tree to the SVG file.
--
\ “I distrust those people who know so well what God wants them |
`\to do to their fellows, because it always coincides with their |
_o__) own desires.” —Susan Browne
d |
_o__) truth.” —Niels Bohr |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
re better and explain more. Alternative explanations that |
_o__) explain nothing are not welcome.” —Victor J. Stenger, 2001-11-05 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
a quicksand |
`\ box. I was an only child... eventually.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
dmin
You should find a Linux job board for that.
--
\ “I distrust those people who know so well what God wants them |
`\to do to their fellows, because it always coincides with their |
_o__) own desires.” —Susan Brownell Anthony, 1896 |
Ben Finney
--
http:
entury what the slave |
`\ trade was to the 16th.” —David Mertz |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
fire, and he will be warm for the rest of his life.” |
_o__) —John A. Hrastar |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
ands working can do more than a thousand clasped in |
`\ prayer.” —Anonymous |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
at
the assignment then fails, but succeeds when clear() is not called.
When should I be calling clear() in this case to maximize speed?
Many thanks,
Ben
--
http://mail.python.org/mailman/listinfo/python-list
y be tempted to re-factor self-contained parts to separate
functions in order to make the code at this location simpler. But it
illustrates the line continuation style I advocate.
--
\“Program testing can be a very effective way to show the |
`\presence of bugs, but is hopelessly inadequate for showing |
_o__) their absence.” —Edsger W. Dijkstra |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
r(some_longer_variables)
> update_spam_statistics(here_and_here)
>
> Which one would you say is more readable?
Mine :-)
--
\ “When I get new information, I change my position. What, sir, |
`\ do you do with new information?” —John Maynard Keynes |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
on forever in a |
`\finite world is either a madman or an economist.” —Kenneth |
_o__) Boulding |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
sts’, feature
tests with Behave http://pypi.python.org/pypi/behave> or something
similar.
--
\ “I tell you the truth: this generation will certainly not pass |
`\ away until all these things [the end of the world] have |
_o__) happened.” —Jesus Christ, c. 30 CE, as quoted in Matthew 24:34 |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
I managed to solve this using the following method:
"""Returns a dictionary of indexes of spectra for which there are secondary
scans, along with the indexes of those scans
"""
scans = dict()
# get an iterable
context = cElementTree.iterparse(self.info['filename']
2004 |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
Walter Hurry writes:
> On Mon, 22 Oct 2012 13:51:35 +1100, Ben Finney wrote:
>
> > Walter Hurry writes:
> >> It is Google bloody Groups which is the problem. I should have
> >> plonked posts from there ages ago, and am about to remedy that
> >> omission.
ething* before your
target into every RE implementation around.
> examples
>
> $hello$ should not be selected but
> not hello but all of the $hello$ and $hello$ ... $hello$ each one
> selected
I have taken your $s to be literal. That's not 100 obvious since $ is a
common (universal?) RE meta-character.
--
Ben.
--
http://mail.python.org/mailman/listinfo/python-list
Rivka Miller writes:
> Thanks everyone, esp this gentleman.
Kind of you to single me out, but it was Janis Papanagnou who first
posted the solution that you say "works best" for you.
--
Ben.
--
http://mail.python.org/mailman/listinfo/python-list
thon-daemon’ development is at
http://lists.alioth.debian.org/mailman/listinfo/python-daemon-devel>.
--
\ “Faith may be defined briefly as an illogical belief in the |
`\ occurrence of the improbable.” —Henry L. Mencken |
_o__)
ve separated us for |
_o__)so long, the consequences of our own actions.” —Douglas Adams |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
“It's dangerous to be right when the government is wrong.” |
`\ —Francois Marie Arouet Voltaire |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
7;ve forgotten this before sometime.” —Steven Wright |
_o__) |
Ben Finney
--
http://mail.python.org/mailman/listinfo/python-list
101 - 200 of 5100 matches
Mail list logo