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


Groups > comp.lang.python > #15318

Re: Design Pattern and Python: Any book recommendation? Your view?

Path csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed5.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail
Return-Path <chris@rebertia.com>
X-Original-To python-list@python.org
Delivered-To python-list@mail.python.org
X-Spam-Status OK 0.007
X-Spam-Evidence '*H*': 0.99; '*S*': 0.00; 'context': 0.04; 'patterns': 0.05; 'subject:Python': 0.06; 'broken.': 0.07; 'closest': 0.07; 'see:': 0.07; 'python': 0.08; 'cherrypy': 0.09; 'higher-level': 0.09; 'indicates': 0.09; 'myself,': 0.09; 'subject:book': 0.09; 'to:addr:comp.lang.python': 0.09; 'url:activestate': 0.09; 'url:peps': 0.09; 'examples': 0.11; 'cc:addr:python-list': 0.15; 'agree.': 0.16; 'any)': 0.16; 'deficiencies': 0.16; 'metaclasses': 0.16; 'newsgroup': 0.16; 'resurrect': 0.16; 'singleton)': 0.16; 'url:blog': 0.17; 'language': 0.17; 'cheers,': 0.18; 'wrote:': 0.18; 'python?': 0.18; "haven't": 0.20; 'suggest': 0.20; 'cc:no real name:2**0': 0.21; "aren't": 0.21; 'discussion': 0.21; 'topic.': 0.23; 'url:dev': 0.23; 'header:In-Reply-To:1': 0.23; 'hopefully': 0.24; "python's": 0.24; 'cc:2**0': 0.25; '(like': 0.25; 'url:code': 0.28; 'tend': 0.28; 'cc:addr:python.org': 0.29; 'message- id:@mail.gmail.com': 0.29; 'url:wiki': 0.29; '(so': 0.30; 'anthony': 0.30; 'pattern': 0.30; 'chris': 0.30; "skip:' 10": 0.30; 'subject:?': 0.31; 'nov': 0.31; 'pm,': 0.31; 'thu,': 0.32; 'pretty': 0.32; 'actually': 0.33; 'it.': 0.33; 'too': 0.33; 'idea': 0.34; 'received:209.85.161': 0.35; 'url:python': 0.35; 'google': 0.36; 'speak': 0.36; 'doing': 0.37; 'reference': 0.37; 'but': 0.37; 'two': 0.37; 'using': 0.37; 'could': 0.38; 'received:google.com': 0.38; 'some': 0.38; 'received:209.85': 0.38; 'url:org': 0.38; 'relatively': 0.38; 'url:docs': 0.38; 'subject:: ': 0.39; 'received:209': 0.40; 'more': 0.60; 'within': 0.60; 'per': 0.61; 'personal': 0.61; 'subject': 0.61; '2011': 0.62; 'market': 0.63; 'alternative': 0.63; 'url:cgi': 0.64; 'view': 0.65; 'view.': 0.67; 'relevant': 0.67; 'buy': 0.68; 'glad': 0.70; 'subject:Design': 0.73; 'subject:Your': 0.78; '2003.': 0.84; 'judges': 0.84; 'kong': 0.84; 'motivating': 0.84; 'prevailing': 0.84; 'sender:addr:chris': 0.84; 'url:2005': 0.84; 'url:rebertia': 0.84; 'url:reference': 0.84; 'variation': 0.84; 'canonical': 0.91; 'give.': 0.91; 'migrating': 0.91; 'subject:view': 0.91
DKIM-Signature v=1; a=rsa-sha256; c=relaxed/relaxed; d=rebertia.com; s=google; h=mime-version:sender:in-reply-to:references:date :x-google-sender-auth:message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=hmASWFKKZ2cXsyhbOekBP1akOUmdXehhXJDKERpl2NY=; b=D7vFRWniyjYDYjrRXI48tOEkZ0mjxxAG0EPDpdxaVkYVQ6SfeYz+Qc9SKp23p8YsiV unoX0nUdkYTHHxFm6FK5ZFJChtIgXfUUR7U8kKsRRFsOz3J8ZmsjWM3jZUxq6SkR3Rbx 4EouFvI8kyQxc2VZT3Cg7OENyaJV4gqBuAWaY=
MIME-Version 1.0
Sender chris@rebertia.com
In-Reply-To <6097694.446.1320366784098.JavaMail.geo-discussion-forums@prap37>
References <6097694.446.1320366784098.JavaMail.geo-discussion-forums@prap37>
Date Thu, 3 Nov 2011 19:15:02 -0700
X-Google-Sender-Auth mpdl18Dz2O-36HJMXJLeAZeoLMM
Subject Re: Design Pattern and Python: Any book recommendation? Your view?
From Chris Rebert <clp2@rebertia.com>
To comp.lang.python@googlegroups.com
Content-Type text/plain; charset=UTF-8
Content-Transfer-Encoding quoted-printable
Cc python-list@python.org
X-BeenThere python-list@python.org
X-Mailman-Version 2.1.12
Precedence list
List-Id General discussion list for the Python programming language <python-list.python.org>
List-Unsubscribe <http://mail.python.org/mailman/options/python-list>, <mailto:python-list-request@python.org?subject=unsubscribe>
List-Archive <http://mail.python.org/pipermail/python-list>
List-Post <mailto:python-list@python.org>
List-Help <mailto:python-list-request@python.org?subject=help>
List-Subscribe <http://mail.python.org/mailman/listinfo/python-list>, <mailto:python-list-request@python.org?subject=subscribe>
Newsgroups comp.lang.python
Message-ID <mailman.2422.1320372912.27778.python-list@python.org> (permalink)
Lines 49
NNTP-Posting-Host 2001:888:2000:d::a6
X-Trace 1320372912 news.xs4all.nl 6941 [2001:888:2000:d::a6]:40083
X-Complaints-To abuse@xs4all.nl
Xref x330-a1.tempe.blueboxinc.net comp.lang.python:15318

Show key headers only | View raw


On Thu, Nov 3, 2011 at 5:33 PM, Anthony Kong <anthony.hw.kong@gmail.com> wrote:
> Sorry to resurrect this topic. By google search the last discussion was in 2003.
>
> I would like to find out what is the current prevailing view or consensus (if any) on the use of Design Pattern in python?

I can only speak for myself, but the whole idea of design patterns is
broken. The existence of nontrivial design patterns indicates language
deficiencies. For more extensive corroborating discussions, see:
http://www.codinghorror.com/blog/2005/06/are-design-patterns-how-languages-evolve.html
http://c2.com/cgi/wiki?AreDesignPatternsMissingLanguageFeatures

Python thankfully has relatively few/minor deficiencies (so long as
one judges it within its dynamic language niche), so design patterns
per se aren't too relevant to it.

The canonical Python-specific design pattern is Borg
(http://code.activestate.com/recipes/66531-singleton-we-dont-need-no-stinkin-singleton-the-bo/
) [a variation on Singleton], and nowadays it (like its parent,
Singleton) is considered to be of dubious utility/advisability.

> I am doing some 'fact-finding' in this area on request of my colleagues. Some of them want to buy a book or two in this subject area. Hopefully the newsgroup can give me some book recommendation and insight in this topic.

The closest alternative would be some publication that gave examples
of using some of Python's fancier, higher-level features, such as
metaclasses and context managers. I haven't been in the market for
such a book, so I have no good recommendations to give. Closest I
could suggest would be the Language Reference
(http://docs.python.org/reference/ ) and relevant PEPs
(http://www.python.org/dev/peps/ ; they tend to include examples by
way of motivating use-cases).

> I myself pretty much subscribe to the view that the nature of python language actually do away much of the need of the use of DP, but it is just a personal view. It comes form my experience of migrating from webware4py (webframework based on J2EE/servlet idea) to cherrypy

I am glad you agree.

Cheers,
Chris
--
http://rebertia.com

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


Thread

Design Pattern and Python: Any book recommendation? Your view? Anthony Kong <anthony.hw.kong@gmail.com> - 2011-11-03 17:33 -0700
  Re: Design Pattern and Python: Any book recommendation? Your view? Roy Smith <roy@panix.com> - 2011-11-03 21:46 -0400
  Re: Design Pattern and Python: Any book recommendation? Your view? Chris Rebert <clp2@rebertia.com> - 2011-11-03 19:15 -0700
  Re: Design Pattern and Python: Any book recommendation? Your view? Ulrich Eckhardt <ulrich.eckhardt@dominolaser.com> - 2011-11-04 10:49 +0100
  Re: Design Pattern and Python: Any book recommendation? Your view? John Roth <johnroth1@gmail.com> - 2011-11-04 05:28 -0700
    Re: Design Pattern and Python: Any book recommendation? Your view? Joe Riopel <goon12@gmail.com> - 2011-11-04 08:41 -0400
  Re: Design Pattern and Python: Any book recommendation? Your view? Andrea Crotti <andrea.crotti.0@gmail.com> - 2011-11-04 12:46 +0000
  Re: Design Pattern and Python: Any book recommendation? Your view? Terry Reedy <tjreedy@udel.edu> - 2011-11-04 15:45 -0400
  Re: Design Pattern and Python: Any book recommendation? Your view? Ned Deily <nad@acm.org> - 2011-11-04 13:11 -0700

csiph-web