importing GriffithXML fails: posters are not added

Bug #1043263 reported by fisimania
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Griffith
Fix Committed
Medium
Michael

Bug Description

Importing Data with the Plugin "GriffithXML" fails. No Posters are added.

Griffith Version: 0.13 (svn Revision 1626)

./griffith --show-dep
gtk :: 2.24.0
gtk.glade :: 2.24.0
sqlalchemy :: 0.7.4
sqlite3 :: 2.6.0 (sqlite-lib 3.7.9)
reportlab :: 2.5
PIL :: True
psycopg2 :: 2.4.5 (dt dec mx pq3 ext)
MySQLdb :: 1.2.3.final.0
chardet :: 2.0.1
sqlite :: 1.0.1
lxml :: True

Debug Log:

E: Griffith(__init__:250): movie details are not unique, skipping
Traceback (most recent call last):
  File "/home/user/griffith/svn/lib/plugins/imp/__init__.py", line 248, in run
    edit.update_image(self.parent, number, poster)
  File "/home/user/griffith/svn/lib/edit.py", line 49, in update_image
    return update_image_from_memory(self, number, imagedata)
  File "/home/user/griffith/svn/lib/edit.py", line 82, in update_image_from_memory
    movie = session.query(db.Movie).filter_by(number=number).one()
  File "/usr/lib/python2.7/dist-packages/sqlalchemy/orm/query.py", line 2020, in one
    raise orm_exc.NoResultFound("No row was found for one()")
NoResultFound: No row was found for one()

Possible Solution:

I think the Query in line 82 from File lib/edit.py returns no row because previous Session operations are not commited.
My Solution is to add the following code before the Query:

session.commit()

After the Change Import works fine.

Revision history for this message
Michael (mikej06) wrote :

Please provide some more detailed information. I tried the import via GriffithXML with posters and it worked without errors.
Can you send me your XML file please?

Revision history for this message
fisimania (fisimania) wrote :

My XML File is a Testfile and was created with the same version and the local SQLite Database.
I then switch to a external MySQL Database and try to import the XML File. Here i become the errors.

MySQL Version is 5.5.24

Importing the XML File into the SQLite Database works for me too.

Revision history for this message
Michael (mikej06) wrote :

Fixed in revision 1628.
Thanks for your report.

Changed in griffith:
assignee: nobody → Michael (mikej06)
importance: Undecided → Medium
milestone: none → 0.13.1
status: New → Fix Committed
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.