Curios issues with Editors

Steve Holden steve at holdenweb.com
Thu Feb 9 07:29:13 EST 2006


rodmc wrote:
> I recently wrote a program in IDLE and it runs perfectly. However when
> the same application is executed within SPE I receive errors  saying
> that certain socket items are not callable, in particular AF_INET.
> 
> I am new to Python, is there a reason why somethings will run in IDLE
> and not SPE?
> 
> I could post the source code but it is changing quite a bit, so this is
> more of a general question than one about a specific bug or issue.
> 
I think you are fooling yourself about this error.

  >>> import socket
  >>> type(socket.AF_INET)
<type 'int'>
  >>>

You would appear to have some code that reads something like

     socket.AF_INET( ... )

which is clearly wrong, since AF_INET is an integer intended to indicate 
the address family required at the creation of a socket.

regards
  Steve
-- 
Steve Holden       +44 150 684 7255  +1 800 494 3119
Holden Web LLC                     www.holdenweb.com
PyCon TX 2006                  www.python.org/pycon/




More information about the Python-list mailing list