[Tutor] No module named player_data
Michael bridges
micha_el2003 at yahoo.com
Mon Jun 6 04:49:13 CEST 2011
one of the things i deleted was __init__.py & __init__.pyc [thought it was not used, then read import again and put it back. still not working]
player_data [folder]
__init__.py
[several .py & .pyc files]
--- On Sun, 6/5/11, Alexandre Conrad <alexandre.conrad at gmail.com> wrote:
> From: Alexandre Conrad <alexandre.conrad at gmail.com>
> Subject: Re: [Tutor] No module named player_data
> To: "Michael bridges" <micha_el2003 at yahoo.com>
> Cc: Tutor at python.org
> Date: Sunday, June 5, 2011, 7:11 PM
> 2011/6/5 Michael bridges <micha_el2003 at yahoo.com>:
> > why does this happen?
> >
> > server [folder]
> > player_data [folder]
> > server.py
> >
> > Traceback (most recent call last):
> > File
> "C:\Users\MySelf\Program\game_stuff\Game_28_02_11\Servers\server_client_begining\server.py",
> line 3, in <module>
> > from player_data import PlayerArmy
> > ImportError: No module named player_data
>
> If player_data is a package (a folder containing an
> __init__.py file),
> I guess you have your class PlayerArmy defined inside the
> __init__.py
> file, or you are importing PlayerArmy from __init__.py.
>
> Could you provide more details on what the "player_data"
> folder contains?
>
> --
> Alex | twitter.com/alexconrad
>
More information about the Tutor
mailing list