Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #63562

Re: Learning python networking

References <22d58d76-f2c2-4a1d-8049-3409ac4665d3@googlegroups.com> <CAPTjJmr-4HbCjqfDjTrjLzvoE4BYr6_OS=BBqRLFg4_BtV4iSw@mail.gmail.com> <CAGGBd_rVOwBT_h0-X72Mhve3DEBg1Qvo6s-PS-=8aKkRXonUKg@mail.gmail.com> <CAPTjJmonGBE2NuRprnJGEUm0tkqTiV=6ucJV9ABYftqtvNRNTQ@mail.gmail.com>
Date 2014-01-08 19:49 -0800
Subject Re: Learning python networking
From Dan Stromberg <drsalists@gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.5229.1389239382.18130.python-list@python.org> (permalink)

Show all headers | View raw


On Wed, Jan 8, 2014 at 4:07 PM, Chris Angelico <rosuav@gmail.com> wrote:
> Maybe it's not the best way to do things, but it can be extremely
> simple in the code.

For small projects, the added complexity doesn't bite you.  At least, not much.

For large projects, with thousands or millions of callbacks, it can be
very difficult to track down bugs in who-knows-which callback, given
that they're all being called asynchronously.  It's vastly simpler to
fire up a debugger against a process, or insert print statements that
are related to each other in time in some way.

> It's
> really easy once you get your head around it.

IMO, it's not a matter of wrapping your head around it, but respecting
complexity.

Three quotes come to mind:
* Make things as simple as possible, but not simpler.
* Fools ignore complexity. Pragmatists suffer it. Some can avoid it.
Geniuses remove it.
* Debugging is twice as hard as writing the code in the first place.
Therefore, if you write the code as cleverly as possible, you are, by
definition, not smart enough to debug it.

I'm not trying to call you or anyone else a fool, but the Alan Perlis
quote (the second) does give a flavor of what I'm trying to say.

The third quote, from Brian Kernighan, seems to underestimate the
complexity of asynchronous programming in the large - it's probably
not just twice as hard.

Back to comp.lang.python | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

Learning python networking Paul Pittlerson <menkomigen6@gmail.com> - 2014-01-08 14:27 -0800
  Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-09 10:29 +1100
    Re: Learning python networking Paul Pittlerson <menkomigen6@gmail.com> - 2014-01-15 02:37 -0800
      Re: Learning python networking Denis McMahon <denismfmcmahon@gmail.com> - 2014-01-15 11:11 +0000
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-15 23:52 +1100
      Re: Learning python networking "Frank Millman" <frank@chagford.com> - 2014-01-15 15:31 +0200
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-16 01:07 +1100
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-16 02:36 +1100
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-16 03:31 +1100
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-16 03:32 +1100
      Re: Learning python networking William Ray Wing <wrw@mac.com> - 2014-01-15 11:43 -0500
      Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-16 04:07 +1100
      Re: Learning python networking William Ray Wing <wrw@mac.com> - 2014-01-15 11:25 -0500
  Re: Learning python networking Dan Stromberg <drsalists@gmail.com> - 2014-01-08 15:53 -0800
  Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-09 11:07 +1100
  Re: Learning python networking Dan Stromberg <drsalists@gmail.com> - 2014-01-08 19:49 -0800
    Re: Learning python networking Alister <alister.ware@ntlworld.com> - 2014-01-09 11:32 +0000
  Re: Learning python networking Chris Angelico <rosuav@gmail.com> - 2014-01-09 15:20 +1100

csiph-web