Python-2.5beta1 crash

Collapse
This topic is closed.
X
X
 
  • Time
  • Show
Clear All
new posts
  • Robin Becker

    #1

    Python-2.5beta1 crash

    I'm testing ReportLab against Python-2.5beta1 and am getting some kind of
    problem as below

    =============== =============== =============== ==========
    C:\Python24\rep ortlab\test>\py thon25\python runAll.py
    ..C:\Python24\r eportlab\test\t est_docstrings. py:54: ImportWarning: Not importing
    directory 'C:\python25\re portlab\tools\u tils': missing __init__.py
    module = __import__(mNam e)
    C:\Python24\rep ortlab\test\tes t_docstrings.py :54: ImportWarning: Not importing d
    irectory 'C:\python25\re portlab\tools\p ythonpoint\demo s': missing __init__.py
    module = __import__(mNam e)
    C:\Python24\rep ortlab\test\tes t_docstrings.py :54: ImportWarning: Not importing d
    irectory 'C:\python25\re portlab\docs': missing __init__.py
    module = __import__(mNam e)
    C:\Python24\rep ortlab\test\tes t_docstrings.py :54: ImportWarning: Not importing d
    irectory 'C:\python25\re portlab\demos': missing __init__.py
    module = __import__(mNam e)
    .....Fatal Python error: non-string found in code slot

    This application has requested the Runtime to terminate it in an unusual way.
    Please contact the application's support team for more information.
    =============== =============== =============== ==========

    First off there may be a bunch of other C extensions involved including PIL, but
    I built them all against this beta. What should I do to refine the error? Do I
    start with trying to establish which of the tests is guilty or build from source
    in debug mode and attempt to find the problem from below.
    --
    Robin Becker

  • Martin v. Löwis

    #2
    Re: Python-2.5beta1 crash

    Robin Becker wrote:
    First off there may be a bunch of other C extensions involved including
    PIL, but I built them all against this beta. What should I do to refine
    the error? Do I start with trying to establish which of the tests is
    guilty or build from source in debug mode and attempt to find the
    problem from below.
    I would personally run Python in debug mode. Set a break point on
    Py_FatalError, and then walk the C stack to see where it comes from.

    Of course, the specific error comes from

    static void
    intern_strings( PyObject *tuple)
    {
    Py_ssize_t i;

    for (i = PyTuple_GET_SIZ E(tuple); --i >= 0; ) {
    PyObject *v = PyTuple_GET_ITE M(tuple, i);
    if (v == NULL || !PyString_Check Exact(v)) {
    Py_FatalError(" non-string found in code slot");
    }
    PyString_Intern InPlace(&PyTupl e_GET_ITEM(tupl e, i));
    }
    }

    which in turn is called from PyCode_New, in these calls:

    intern_strings( names);
    intern_strings( varnames);
    intern_strings( freevars);
    intern_strings( cellvars);

    So it appears you are trying to create a code object, where
    a name, varname, freevar name, or cellvar name is not a string.
    This is indeed fatal: names in Python are always strings.

    Regards,
    Martin

    Comment

    Working...