Finding the file referred to in a Python traceback

Discussion in 'Python' started by metaperl.etc@gmail.com, Sep 26, 2006.

  1. Guest

    In this traceback, the path to 3 different SQL Alchemy source files is
    a relative directory. However, no such directory is below my current
    working directory.

    This is problematic for two reasons:
    1 - I cannot use XEmacs find-file-at-point to find the file in which
    the error is occurring
    2 - I am not really sure where the source file is that is causing
    problems because tha path could be relative to anything.

    --- output ---

    Traceback (most recent call last):
    File "<stdin>", line 1, in ?
    File "conf/__init__.py", line 34, in __init__
    self.table = tables(self.metadata)
    File "conf/__init__.py", line 38, in __init__
    self.users = Table('Users', metadata, autoload=True)
    File "build/bdist.darwin-8.7.1-i386/egg/sqlalchemy/schema.py", line
    138, in __call__
    File "build/bdist.darwin-8.7.1-i386/egg/sqlalchemy/engine/base.py",
    line 495, in reflecttable
    File
    "build/bdist.darwin-8.7.1-i386/egg/sqlalchemy/databases/mssql.py", line
    426, in reflecttable
    TypeError: __init__() takes at most 2 arguments (3 given)
    >>> import sys
    >>> print sys.path

    ['', '/sw/lib/python2.4/site-packages/Dabo-0.6.5s-py2.4.egg',
    '/sw/lib/python2.4/site-packages/SQLAlchemy-0.2.8dev_r1898-py2.4.egg',
    '/sw/lib/python24.zip', '/sw/lib/python2.4',
    '/sw/lib/python2.4/plat-darwin', '/sw/lib/python2.4/plat-mac',
    '/sw/lib/python2.4/plat-mac/lib-scriptpackages',
    '/sw/lib/python2.4/lib-tk', '/sw/lib/python2.4/lib-dynload',
    '/sw/lib/python2.4/site-packages',
    '/sw/lib/python2.4/site-packages/Numeric',
    '/sw/lib/python2.4/site-packages/PIL',
    '/sw/lib/python2.4/site-packages/gtk-2.0',
    '/sw/lib/python2.4/site-packages/pythonutils',
    '/sw/lib/python2.4/site-packages/wx-2.6-gtk2-unicode']
    >>>
     
    , Sep 26, 2006
    #1
    1. Advertising

  2. <> wrote:
    >In this traceback, the path to 3 different SQL Alchemy source files is
    >a relative directory. However, no such directory is below my current
    >working directory.
    >
    >Traceback (most recent call last):
    > File "<stdin>", line 1, in ?
    > File "conf/__init__.py", line 34, in __init__
    > self.table = tables(self.metadata)
    > File "conf/__init__.py", line 38, in __init__
    > self.users = Table('Users', metadata, autoload=True)
    > File "build/bdist.darwin-8.7.1-i386/egg/sqlalchemy/schema.py", line
    >138, in __call__

    [etc]
    >>>> print sys.path

    >['', '/sw/lib/python2.4/site-packages/Dabo-0.6.5s-py2.4.egg',
    >'/sw/lib/python2.4/site-packages/SQLAlchemy-0.2.8dev_r1898-py2.4.egg',

    [etc]

    Paths of files contained in eggs aren't always helpful (as was pointed
    out to me recently). If you unzip the SQLAlchemy egg (eggs are just
    zip files) (to somewhere other than site-packages if you want to avoid
    confusion) you'll probably find schema.py etc. in there.

    --
    \S -- -- http://www.chaos.org.uk/~sion/
    ___ | "Frankly I have no feelings towards penguins one way or the other"
    \X/ | -- Arthur C. Clarke
    her nu becomeþ se bera eadward ofdun hlæddre heafdes bæce bump bump bump
     
    Sion Arrowsmith, Sep 28, 2006
    #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. Michael Tholkes
    Replies:
    2
    Views:
    422
    Yan-Hong Huang[MSFT]
    Jun 30, 2003
  2. Paul
    Replies:
    5
    Views:
    391
    Eliyahu Goldin
    Mar 16, 2006
  3. Jody Burgess
    Replies:
    2
    Views:
    549
    George Kinney
    Jul 17, 2004
  4. jeniffer
    Replies:
    12
    Views:
    789
    Jordan Abel
    Mar 29, 2006
  5. Jack Bates
    Replies:
    0
    Views:
    281
    Jack Bates
    May 2, 2011
Loading...

Share This Page