Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem w/ sqlite database result storage. #11

Open
jenisys opened this issue Mar 10, 2012 · 2 comments
Open

Problem w/ sqlite database result storage. #11

jenisys opened this issue Mar 10, 2012 · 2 comments

Comments

@jenisys
Copy link
Contributor

jenisys commented Mar 10, 2012

Running simple test w/ non-existing database results storage fails.

$ multimech-run my_project
...
loading results into database: sqlite:///results.db

Traceback (most recent call last):
  File "/Library/Frameworks/Python.framework/Versions/Current/bin/multimech-run", line 9, in <module>
    load_entry_point('multi-mechanize==1.2.0', 'console_scripts', 'multimech-run')()
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/multimechanize/utilities/run.py", line 64, in main
    run_test()
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/multimechanize/utilities/run.py", line 144, in run_test
    import multimechanize.resultsloader
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/multimechanize/resultsloader.py", line 69, in <module>
    class ResultRow(Base):
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/sqlalchemy/ext/declarative.py", line 1336, in __init__
    _as_declarative(cls, classname, cls.__dict__)
  File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-packages/sqlalchemy/ext/declarative.py", line 1104, in _as_declarative
    "__table_args__ value must be a tuple, "
sqlalchemy.exc.ArgumentError: __table_args__ value must be a tuple, dict, or None

VERSION-INFO:

  • multi-mechanize 1.2.0
  • SQLAlchemy 0.7.5
  • OS: MACOSX 10.7

CONFIG-FILE:
results_database = sqlite:///results.db

@boicy
Copy link

boicy commented Mar 29, 2012

I'm getting the same problem running on CentOS 6 with the same version of SQLAlchemy - I uninstalled and installed SQLAlchemy==0.6 and it now works...

@esoergel
Copy link

I got the same problem with multi-mechanize 1.2.0. It looks like there's a missing comma in the __table_args__ definition, so it doesn't register as a tuple. This was fixed in December of 2012, but it looks like the fix hasn't made it through to the version you get with pip install. Add it in yourself and it should work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants