Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > comp.lang.python > #52984
| Path | csiph.com!newsfeed.hal-mli.net!feeder3.hal-mli.net!newsfeed.hal-mli.net!feeder1.hal-mli.net!newsfeed.xs4all.nl!newsfeed4.news.xs4all.nl!xs4all!newsgate.cistron.nl!newsgate.news.xs4all.nl!post.news.xs4all.nl!not-for-mail |
|---|---|
| Return-Path | <mohsen@pahlevanzadeh.org> |
| X-Original-To | python-list@python.org |
| Delivered-To | python-list@mail.python.org |
| X-Spam-Status | OK 0.001 |
| X-Spam-Evidence | '*H*': 1.00; '*S*': 0.00; 'python.': 0.02; 'repository': 0.05; 'duplicate': 0.07; 'error:': 0.07; 'imported': 0.09; 'latter': 0.09; 'obj': 0.09; 'cc:addr:python-list': 0.11; 'python': 0.11; 'eclipse': 0.16; 'nameerror:': 0.16; 'questioned': 0.16; 'subject:programming': 0.16; 'subject:python': 0.16; 'wrote:': 0.18; 'all,': 0.19; 'trying': 0.19; 'code,': 0.22; 'programming': 0.22; 'import': 0.22; 'portion': 0.22; 'cc:addr:python.org': 0.22; 'install': 0.23; 'module,': 0.24; 'question': 0.24; 'cc:2**0': 0.24; 'cc:no real name:2**0': 0.24; "i've": 0.25; 'post': 0.26; 'defined': 0.27; 'header:In-Reply- To:1': 0.27; 'statement': 0.30; "i'm": 0.30; 'class': 0.32; 'run': 0.32; 'there,': 0.34; 'could': 0.34; 'something': 0.35; 'thank': 0.38; 'sure': 0.39; 'either': 0.39; 'dave': 0.60; 'materials': 0.61; 'new': 0.61; "you're": 0.61; 'first': 0.61; "you'll": 0.62; 'name': 0.63; 'dear': 0.65; 'study': 0.69; 'angel': 0.91 |
| DKIM-Signature | v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=pahlevanzadeh.org; s=default; h=Content-Transfer-Encoding:Mime-Version:Content-Type:References:In-Reply-To:Date:Cc:To:From:Subject:Message-ID; bh=p/J7T8/Id9ZvR8GJxG0yNAvRekVryl3wQ8UD2+qZW2U=; b=n/Hm8Qj/52uaVnMtpKtFwS9T0rP8EMWdYV5fdyfXO6JLoNkQy3OIlCn7iz9fzYCQBylkl17GEdq9nX2cZiYFnBasG/JP1NnXAZtQaBaf/vdzWeKaFBJ43ZJVQ3J+TdQr5yqKv1K6YC1wV0o3IGKcTENp/NaVlOKAP5W7e2rn9Jc=; |
| Subject | Re: multifile programming on python 3 |
| From | Mohsen Pahlevanzadeh <mohsen@pahlevanzadeh.org> |
| To | Dave Angel <davea@davea.name> |
| Date | Mon, 26 Aug 2013 00:01:30 +0430 |
| In-Reply-To | <kvcsd1$eap$1@ger.gmane.org> |
| References | <1377418600.6069.9.camel@debian> <kvcsd1$eap$1@ger.gmane.org> |
| Content-Type | text/plain; charset="UTF-8" |
| X-Mailer | Evolution 3.4.4-4+b1 |
| Mime-Version | 1.0 |
| Content-Transfer-Encoding | 7bit |
| X-AntiAbuse | This header was added to track abuse, please include it with any abuse report |
| X-AntiAbuse | Primary Hostname - part7.royal-servers.com |
| X-AntiAbuse | Original Domain - python.org |
| X-AntiAbuse | Originator/Caller UID/GID - [47 12] / [47 12] |
| X-AntiAbuse | Sender Address Domain - pahlevanzadeh.org |
| X-Get-Message-Sender-Via | part7.royal-servers.com: authenticated_id: mohsen@pahlevanzadeh.org |
| Cc | python-list@python.org |
| X-BeenThere | python-list@python.org |
| X-Mailman-Version | 2.1.15 |
| 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.225.1377459100.19984.python-list@python.org> (permalink) |
| Lines | 71 |
| NNTP-Posting-Host | 2001:888:2000:d::a6 |
| X-Trace | 1377459100 news.xs4all.nl 15985 [2001:888:2000:d::a6]:44729 |
| X-Complaints-To | abuse@xs4all.nl |
| Xref | csiph.com comp.lang.python:52984 |
Show key headers only | View raw
On Sun, 2013-08-25 at 12:13 +0000, Dave Angel wrote: > Mohsen Pahlevanzadeh wrote: > > > Dear all, > > > > I need help about multifile programming on python 3 and i questioned on > > stackoverflow : > > http://stackoverflow.com/questions/18391230/eclipse-python-nameerror-name-mymodule-is-not-defined > > > > I thank you if you answer me. > > > > --mohsen > > You have a response there, so I'm not sure why you're trying to > duplicate it here. > > A portion of your question there: > > > > > import repository; > > > > > > x = Repository(); > > When i run my application, i get the following error: > > > > x = Repository(); > > > > NameError: name 'Repository' is not defined > > That's not the whole error, that's just the last line of it. Still the > immediate answer is clear: > > after the statement > import repository > > one new symbol is available to your code, the symbol 'repository' > > if you want to use something defined in that imported module, then use > > obj = repository.Repository() > > > > Or you could do one of these two: > > import repository > Repository = repository.Repository #defines new name for the class > Materials = repository.Materials #ditto > > or > > from repository import Repository, Materials > > > In either of those latter cases, you could now create the object by > > obj = Repository() > > As for the Eclipse problem, you'll have to study the other answer; I've > never found it worthwhile to install Eclipse for Python. > > -- > DaveA > > At first , thank you, When i post into ML, i get answer on stackoverflow. --mohsen
Back to comp.lang.python | Previous | Next | Find similar | Unroll thread
Re: multifile programming on python 3 Mohsen Pahlevanzadeh <mohsen@pahlevanzadeh.org> - 2013-08-26 00:01 +0430
csiph-web