where to find information about errors/exceptions in socket.py

Discussion in 'Python' started by mirandacascade@yahoo.com, Oct 7, 2005.

  1. Guest

    Version of python: 2.4
    O/S: Win2K

    I will be writing some python scripts to do some client-side
    programming that involves socket.py. I expect that I will be making
    calls to the following methods/functions:

    connect_ex()
    setsockopt()
    sendall()
    recv()
    close()

    Where can one find information about whether the functions/methods
    above return error codes that provide some indication as to whether the
    function/method succeeded? Is there an exception class for handling
    exceptions raised in socket.py? If so, where can one find information
    about it?

    I consulted the docstrings and didn't find much about return codes or
    exception classes. Also looked at the Lutz "Programming Python"
    text...it devotes several pages to socket programming, but I didn't
    observe much with regard to error/exception handling.
     
    , Oct 7, 2005
    #1
    1. Advertising

  2. Steve Holden Guest

    wrote:
    > Version of python: 2.4
    > O/S: Win2K
    >
    > I will be writing some python scripts to do some client-side
    > programming that involves socket.py. I expect that I will be making
    > calls to the following methods/functions:
    >
    > connect_ex()
    > setsockopt()
    > sendall()
    > recv()
    > close()
    >
    > Where can one find information about whether the functions/methods
    > above return error codes that provide some indication as to whether the
    > function/method succeeded? Is there an exception class for handling
    > exceptions raised in socket.py? If so, where can one find information
    > about it?
    >
    > I consulted the docstrings and didn't find much about return codes or
    > exception classes. Also looked at the Lutz "Programming Python"
    > text...it devotes several pages to socket programming, but I didn't
    > observe much with regard to error/exception handling.
    >

    I'd suggest reading the documentation myself:

    http://docs.python.org/lib/module-socket.html

    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/
     
    Steve Holden, Oct 7, 2005
    #2
    1. Advertising

Want to reply to this thread or ask your own question?

It takes just 2 minutes to sign up (and it's free!). Just click the sign up button to choose a username and then you can ask your own questions on the forum.
Similar Threads
  1. Mark Goldin

    Errors, errors, errors

    Mark Goldin, Jan 17, 2004, in forum: ASP .Net
    Replies:
    2
    Views:
    1,005
    Mark Goldin
    Jan 17, 2004
  2. Laszlo Nagy
    Replies:
    1
    Views:
    5,003
    Mark Wooding
    Jan 27, 2009
  3. Jean-Paul Calderone
    Replies:
    0
    Views:
    1,012
    Jean-Paul Calderone
    Jan 27, 2009
  4. Laszlo Nagy
    Replies:
    0
    Views:
    581
    Laszlo Nagy
    Feb 1, 2009
  5. Steve Holden
    Replies:
    0
    Views:
    699
    Steve Holden
    Feb 1, 2009
Loading...

Share This Page