Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #26401
| Path | csiph.com!usenet.pasdenom.info!weretis.net!feeder4.news.weretis.net!feeds.phibee-telecom.net!newsfeed.xs4all.nl!newsfeed6.news.xs4all.nl!xs4all!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <d@davea.name> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.006 |
| X-Spam-Evidence | '*H*': 0.99; '*S*': 0.00; 'importing': 0.04; 'attributes': 0.07; 'class,': 0.07; 'works.': 0.07; 'wrapper': 0.07; 'python': 0.09; 'cc:addr:python-list': 0.10; 'files.': 0.13; 'illustrating': 0.16; 'one)': 0.16; 'possible?': 0.16; 'programmers.': 0.16; 'sentences.': 0.16; 'temp': 0.16; 'wrote:': 0.17; 'code.': 0.20; 'import': 0.21; 'supposed': 0.21; 'finally,': 0.22; 'object.': 0.22; 'parse': 0.22; 'defined': 0.22; 'cc:2**0': 0.23; 'example': 0.23; 'cc:no real name:2**0': 0.24; 'least': 0.25; 'cc:addr:python.org': 0.25; 'header:In-Reply-To:1': 0.25; 'header:User-Agent:1': 0.26; 'am,': 0.27; 'mind.': 0.27; 'declared': 0.29; 'kumar': 0.29; 'necessary,': 0.29; 'surprised': 0.29; 'source': 0.29; 'class': 0.29; 'classes': 0.30; 'query': 0.30; 'code': 0.31; 'file': 0.32; 'list': 0.35; 'problem,': 0.35; 'there': 0.35; 'list.': 0.35; 'explain': 0.36; 'modules': 0.36; 'correctly': 0.37; 'being': 0.37; 'subject:: ': 0.38; 'files': 0.38; 'object': 0.38; 'some': 0.38; 'received:192': 0.39; 'build': 0.39; 'called': 0.39; 'where': 0.40; 'received:192.168': 0.40; 'help': 0.40; 'your': 0.60; 'below,': 0.60; 'different': 0.63; 'show': 0.63; 'header:Reply-To:1': 0.68; 'lose': 0.71; 'received:74.208': 0.71; 'reply-to:no real name:2**0': 0.72; '(yes,': 0.84; '2.7.': 0.84; 'received:74.208.4.194': 0.84; 'significance': 0.84 |
| Date | Thu, 02 Aug 2012 07:04:15 -0400 |
| From | Dave Angel <d@davea.name> |
| User-Agent | Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120714 Thunderbird/14.0 |
| MIME-Version | 1.0 |
| To | Shanth Kumar <shanthulinux@gmail.com> |
| Subject | Re: attribute is accessed from Nonetype |
| References | <CAMLC9n6ES9CwCE_OqEsnvQJ1gG_2MJEmrkjzQaM7tPQ4-4k0nA@mail.gmail.com> |
| In-Reply-To | <CAMLC9n6ES9CwCE_OqEsnvQJ1gG_2MJEmrkjzQaM7tPQ4-4k0nA@mail.gmail.com> |
| Content-Type | text/plain; charset=ISO-8859-1 |
| Content-Transfer-Encoding | 7bit |
| X-Provags-ID | V02:K0:jgedVB5pQs9UTbHAOPnU3R3EoFfgGeK2HOjBzXs8TET FfnxWcCgdylekRxFZawpx3fubMQKrkzsEhz0gOJI8MC1BMyq5X JYbchscrQsflo3YX9exTR5pLfAusSUR16/1ihfr9Yqv5CfPot6 cDKud4YSf56Ry5kzfagtTQFR7XC+4a7IAzpQ+r941u3QTjvvNb P7Txame6GSVJ7DXQ/UU8VAwGWrlFxgUsNPbeAi0D2854jlfZ05 KKuL8GIDcEQTYHY4MRz5x7vR2IZzRcjTE2HhLWNXgSTCbMAnHw slUH08AUloFPLw46zfgaAf1G+kxgI10oxn3Hpx7msjX/q3Mtg= = |
| Cc | python-list@python.org |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.12 |
| Precedence | list |
| Reply-To | d@davea.name |
| 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.2869.1343905484.4697.python-list@python.org> (permalink) |
| Lines | 41 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1343905484 news.xs4all.nl 6898 [2001:888:2000:d::a6]:37795 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:26401 |
Show key headers only | View raw
On 08/02/2012 06:28 AM, Shanth Kumar wrote: > Hi ,All, > I am Shanthkumar. Good to see the mailing list for python programmers. Welcome to the list. > Please find my query below, > > In my source code in a python file e.g xyz.py couple of classes are defined > also there is a wrapper class, a none object is declared in the file e.g > temp=None > from temp some attributes are being accessed in the files that are > importing xyz.py > even though temp is not initialised to any other object still it is none > object attributes are being accessed from None object.Is there any > significance of wrapper class here..? > Can you please help me. > > Once you actually supply some code. Build a small example illustrating your problem, and explain better what is wrong/unexpected with how it works. If an import of xyz.py is necessary, then show both files. Are you surprised that the None object has attributes? It has at least 15 in Python 2.7. Or are you surprised that temp is different in other modules than it is in xyz.py ? Or are you surprised that wrapping a NoneType is possible? Also, please use the names correctly and consistently. The None object (yes, there is only one) is not the same as a none object. And there is no standard type called Nonetype. Finally, please avoid runon sentences. By the time we parse where the periods are supposed to be, we just may lose the meaning you had in mind. -- DaveA
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: attribute is accessed from Nonetype Dave Angel <d@davea.name> - 2012-08-02 07:04 -0400
csiph-web