caspergasper / Gready-Android

Android app for http://www.goodreads.com/
11 stars 4 forks source link

Error opening shelf with odd book (was: nonstandard large exclusive shelf) #5

Closed Cait closed 14 years ago

Cait commented 14 years ago

Trying to open a nonstandard (not read/currently-reading/to-read) exclusive shelf with 406 books gave a "not well-formed (invalid token)" error at line 5159, column 71

This is the website page for the shelf in question, and the 92nd book (the one where the app breaks) is "Hilbert" by Constance Bowman Reid: http://www.goodreads.com/review/list/1005037?shelf=looks-interesting

Steps: opened app for the first time, authenticated, and was in updates view hit menu hit bookshelves from pop-up selected looks-interesting (exclusive shelf with 406 books) error!

error is: ERROR! java.lang.RuntimeException: org.apache.harmony.xml.ExpatParser$ParseException: At line 5159, column 71: not well-formed (invalid token)

clicked ok shelf opened in "date added desc" order, appears to have been cut off in the middle of the 92nd book record hit menu, bookshelves again from pop-up selected not-reading (nonstandard exclusive shelf with 9 books) shelf loaded fully hit menu, bookshelves again, selected looks-interesting from pop-up again error!

error is the same as before: ERROR! java.lang.RuntimeException: org.apache.harmony.xml.ExpatParser$ParseException: At line 5159, column 71: not well-formed (invalid token)

returned briefly to the display of the not-reading shelf and then stopped

SORRY! The application Goodreads (process com.caspergasper.android.goodreads) has stopped unexpectedly. Please try again.

hit force close screen blanked except for phone's status bar and then stopped again

SORRY! The application Goodreads (process com.caspergasper.android.goodreads) has stopped unexpectedly. Please try again.

hit force close then application closed

after rebooting, the same sequence of actions caused the same error when loading the looks-interesting shelf, but the read shelf (with 1484 books) loaded the first hundred books fully and without error.

caspergasper commented 14 years ago

Many thanks for your excellent bug reporting :-)

I'll take a look and see if there's anything in particular about the book in your list -- I should be able to reproduce it here. non-standard lists shouldn't be a problem, and as you correctly surmized, I've arbitrarily set the limit to 100 books to avoid eating too much memory. (Fixing this properly is also on my TODO list).

Casper.

caspergasper commented 14 years ago

Confirmed, I added this book: http://www.goodreads.com/book/show/1217018.Hilbert

to my booklist and I get the same exception too. Failure to parse CDATA sections should not be fatal.

caspergasper commented 14 years ago

This is fixed for me in the latest .apk file -- can you please download and try it? thanks

Cait commented 14 years ago

I no longer get the error when opening the shelf containing this book, but the listing does cut off in the same way when it reaches that book.

Cait commented 14 years ago

Other shelves on which I've placed this book also cut off when they reach it -- it appears to be a problem with this specific record. At a guess, could it be a bad character in the book description? I won't fix the book record's description to clean it up (I'm a GR librarian and could edit the record) so that you can keep it for testing.

caspergasper commented 14 years ago

That's strange, I added Hilbert to my bookshelf and I get no description for it but books below appearing. (Was it a different book?) I think your shelf is public so I can try directly and see.

Yes, it is a bad character in the description and doesn't render correctly on the site either as you can see here: http://www.goodreads.com/book/show/1217018.Hilbert -- "David Hilbert, Director of the Mathematical Institute of G\uffffttingen "

Unrelated, as a librarian can you fix this book for me -- http://www.goodreads.com/book/show/7847069-unreliable-sources

It's the wrong John Simpson, should be this one -- http://www.goodreads.com/author/show/55701.John_Cody_Fidler_Simpson

thanks,

Casper.

caspergasper commented 14 years ago

Can you hit this link: http://www.goodreads.com/review/list?format=xml&key=UvPjrkah6sJXg88qs75xRA&shelf=mathematics

and send me the XML file please?

casper.gasper@gmail.com

Cait commented 14 years ago

Sent!

caspergasper commented 14 years ago

Ah, OK -- I can see the problem. It is cutting off all books below it, but only in the current XML file -- further XML files are processed as normal.

caspergasper commented 14 years ago

This is fixed for me in the latest build (20100626) -- can you please try?

thanks, Casper.

Cait commented 14 years ago

Yes, it's working for me too in the new build, and even the book description in the pop-up is handling the bad character now.

Thank you!

caspergasper commented 14 years ago

Great, I'll close this one.