Problem with mxDateTime on HPUX 11.11 machine !

Discussion in 'Python' started by Tien Nguyen, Aug 27, 2003.

  1. Tien Nguyen

    Tien Nguyen Guest

    Hi There,

    I installed python2.3 (configured with option
    --with-libs='lpthread -lcl'), and egenix-mx-base-2.0.5 on an HPUX
    B.11.11 machine. Everything seems to be OK. I can start python and
    import mx modules successfully.

    tnguyen@local_host:/users/denver/tnguyen 71 % python
    Python 2.3 (#1, Aug 26 2003, 16:06:40)
    [GCC 3.1] on hp-ux11
    Type "help", "copyright", "credits" or "license" for more information.
    >>> from mxDateTime import *
    >>> from mxDateTime import __version__
    >>> from DateTime import *
    >>> from DateTime import __version__
    >>>


    The problem was that, in my c program, I call the python API:

    PyObject* call_module = PyImport_ImportModule("module_name");

    call_module always NULL and I got the following error on screen:

    *** You don't have the (right) mxDateTime binaries installed !

    I think this message comes from:
    python_home/lib/python2.3/site-packages/mx/DateTime/mxDateTime/__init__.py
    ----------------------------------------------------------
    """ mxDateTime - Date and time handling routines and types

    Copyright (c) 2000, Marc-Andre Lemburg; mailto:
    Copyright (c) 2000-2001, eGenix.com Software GmbH;
    mailto:
    See the documentation for further information on copyrights,
    or contact the author. All Rights Reserved.
    """
    try:
    from mxDateTime import *
    from mxDateTime import __version__
    except ImportError, why:
    print "*** You don't have the (right) mxDateTime binaries
    installed !"
    raise ImportError, why
    #from mxDateTime_Python import *
    #from mxDateTime_Python import __version__

    # Python part of the intialization
    try:
    import time
    setnowapi(time.time)
    del time

    except NameError:
    pass
    --------------------------------------------
    I don't know why it always raise exception like that!?

    Can any python expert or mxBase expert help me with this?

    Thank you very much.

    Tien Nguyen
     
    Tien Nguyen, Aug 27, 2003
    #1
    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. Dave Harrison

    MySQLdb and egenix mxDateTime dumps core

    Dave Harrison, Aug 5, 2003, in forum: Python
    Replies:
    0
    Views:
    353
    Dave Harrison
    Aug 5, 2003
  2. Michael R Seefelt

    C-program->Python->mxDateTime Problem

    Michael R Seefelt, Jun 2, 2004, in forum: Python
    Replies:
    1
    Views:
    715
    fishboy
    Jun 6, 2004
  3. Prashant Pai

    mxDateTime package question

    Prashant Pai, Oct 12, 2004, in forum: Python
    Replies:
    2
    Views:
    290
    Eddie Corns
    Oct 13, 2004
  4. M.-A. Lemburg
    Replies:
    0
    Views:
    393
    M.-A. Lemburg
    Dec 6, 2004
  5. Replies:
    3
    Views:
    428
    Michael Maibaum
    Mar 7, 2005
Loading...

Share This Page