[Author Prev][Author Next][Thread Prev][Thread Next][Author Index][Thread Index]
[pygame] Python path problem in vista?
- To: pygame-users@xxxxxxxx
- Subject: [pygame] Python path problem in vista?
- From: Thiago Chaves <shundread@xxxxxxxxx>
- Date: Sun, 8 Feb 2009 22:02:52 +0200
- Delivered-to: archiver@xxxxxxxx
- Delivered-to: pygame-users-outgoing@xxxxxxxx
- Delivered-to: pygame-users@xxxxxxxx
- Delivery-date: Sun, 08 Feb 2009 15:03:01 -0500
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:date:message-id:subject :from:to:content-type; bh=dmmikoVjEHuOErGLArt/42CERT5R+VsQy6vST3WxfO8=; b=wtTeV6AZQcEzGbC34GpGqLD51/+Au4xqfRPc2VCFvl6lxDl1LEUy+PTpPfqLTzHwpq MrDhcyPXQxdUwjYRszhKtKPlsvoORqj5xNdj7dMuUnZiilroQTDsn5QkfjkFSpKVxU55 hlPR03E2M7KegqiX5m/jBsd/qAP4bfBW5wxjc=
- Domainkey-signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:date:message-id:subject:from:to:content-type; b=cUH1ZRRpSfvWmkKYAl0a1c5TgNdma8+dt+AA1CON5B21mkQxaRxmRXXYkQLqkcD8ar 9elJQBTRjP5oAPx3vkGG1Q3zCp06GE/tJPPodSPUzPHmfdn1zD6UGDhc/KEzCktsIZf3 dn6CYwrZet+CURND+UuH0KZ0VokDU+jms5npA=
- Reply-to: pygame-users@xxxxxxxx
- Sender: owner-pygame-users@xxxxxxxx
Hi,
recently I was informed that my most recent project is not running
properly in Vista. I'm using the skellington structure suggested by
Pyweek administration and I'm wondering if that's somehow related.
File structure for the project (as far as it is relevant to this post):
ssof/run_game.py
ssof/lib/main.py
run_game.py's contents:
____________________
#! /usr/bin/env python
import sys
import os
try:
__file__
except NameError:
pass
else:
libdir = os.path.abspath(os.path.join(os.path.dirname(__file__), 'lib'))
sys.path.insert(0, libdir)
import main
main.main()
_______________
User feedback:
Alright then,
Open fully-updated Windows Vista. Open IDLE. Python version number is
2.5.2. Open run_game.py. Hit F5 (runs the script).
Traceback (most recent call last):
File "C:\Users\Andy
Hanson\Desktop\ssof-2009-01-31-fixed\ssof_alpha4\run_game.py", line
15, in <module>
import main
ImportError: No module named main
This is certainly a very simple problem!
________________
Any thoughts? What am I doing wrong here?
(I'm attaching run_game.py just in case the formatting gets messed up)
-Thiago
#! /usr/bin/env python
import sys
import os
try:
__file__
except NameError:
pass
else:
libdir = os.path.abspath(os.path.join(os.path.dirname(__file__), 'lib'))
sys.path.insert(0, libdir)
import main
main.main()