ASPN ActiveState Programmer Network
ActiveState
/ Home / Perl / PHP / Python / Tcl / XSLT /
/ Safari / My ASPN /
Cookbooks | Documentation | Mailing Lists | Modules | News Feeds | Products | User Groups


Recent Messages
List Archives
About the List
List Leaders
Subscription Options

View Subscriptions
Help

View by Topic
ActiveState
.NET Framework
Open Source
Perl
PHP
Python
Tcl
Web Services
XML & XSLT

View by Category
Database
General
SOAP
System Administration
Tools
User Interfaces
Web Programming
XML Programming


MyASPN >> Mail Archive >> pygame-users
pygame-users
Re: [pygame] pygame from OS X command line
by Bob Ippolito other posts by this author
Aug 3 2005 10:51PM messages near this date
[pygame] pygame from OS X command line | Re: [pygame] pygame from OS X command line
On Aug 3, 2005, at 6:47 PM, Ben Willmore wrote:

>  I was excited to see on Bob Ippolito's website that he has updated  
>  OS X pygame so it will run without either pythonw or being in an  
>  app bundle.  However, I found when running pygame (today's CVS)  
>  from fink python2.4, I got the following error:
> 
>  ---
>  [ben@assam ben] $ python2.4
>  Python 2.4.1 (#1, Aug  2 2005, 23:12:54)
>  [GCC 4.0.0 (Apple Computer, Inc. build 5026)] on darwin
>  Type "help", "copyright", "credits" or "license" for more information.
>  >>> import pygame
>  pygame.init()
>  >>> pygame.init()
>  (6, 0)
>  >>> screen = pygame.display.set_mode((468, 60))
>  2005-08-03 21:37:01.917 python2.4[26902] *** Uncaught exception:  
>  <NSInternalInconsistencyException> Error (1002) creating CGSWindow
>  Trace/BPT trap

The actual problem is that you're spending too much time before  
creating the screen... your fix works around that problem by calling  
NSApplicationLoad on import, but it breaks the detection that goes on  
later in pygame.macosx to see if pygame is already running in the  
context of an application and will break other things.

Try this instead, with no patch:
python -i -c "import pygame; pygame.init()"

-bob
Thread:
Ben Willmore
Bob Ippolito
Bob Ippolito
Ben Willmore
Ben Willmore
Bob Ippolito
Ben Willmore
Bob Ippolito
Ben Willmore
Bob Ippolito
Ben Willmore
Bob Ippolito
Ben Willmore

Privacy Policy | Email Opt-out | Feedback | Syndication
© ActiveState Software Inc. All rights reserved