TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2014-12-14
Hey there,
when you scrape movie-items with TMM, after "NFO Watchedstate Updater" changes them (barely), TMM can't re-read the .nfo files.
I narrowed the problem down to this (simplified example!):
.nfo file from TMM scraping:
Code: <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<!-- created on 2014-12-14 15:12:30 - tinyMediaManager 2.6.4 -->
<movie>
<title>A MovieName here</title>
<originaltitle>A MovieName here</originaltitle>
<set></set>
<sorttitle></sorttitle>
<rating>6.8</rating>
<year>2013</year>
<top250></top250>
<votes>464</votes>
<outline>Text Text Text Text Text Text Text Text Text Text Text Text Text</outline>
<plot>Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text</plot>
<tagline>Text Text Text Text </tagline>
<runtime>116</runtime>
<thumb></thumb>
<mpaa>DE:FSK 16 / DE:FSK16 / DE:16 / DE:ab 16</mpaa>
<certification>DE:FSK 16 / DE:FSK16 / DE:16 / DE:ab 16</certification>
<id>11111111111111111111</id>
<ids>
<entry>
<key>tmdbId</key>
<value xsi:type="xs:int" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1111111111</value>
</entry>
<entry>
<key>imdbId</key>
<value xsi:type="xs:string" xmlns:xs="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">1111111111</value>
</entry>
</ids>
<watched>false</watched>
<playcount>0</playcount>
</movie>
.nfo file alfter altering and cleanup from "NFO Watchedstate Updater":
Code: <?xml version='1.0' encoding='UTF-8'?>
<movie xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
<title>A MovieName here</title>
<originaltitle>A MovieName here</originaltitle>
<set />
<sorttitle />
<rating>6.8</rating>
<year>2013</year>
<top250 />
<votes>464</votes>
<outline>Text Text Text Text Text Text Text Text Text Text Text Text Text</outline>
<plot>Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text Text</plot>
<tagline>Text Text Text Text </tagline>
<runtime>116</runtime>
<thumb />
<mpaa>DE:FSK 16 / DE:FSK16 / DE:16 / DE:ab 16</mpaa>
<certification>DE:FSK 16 / DE:FSK16 / DE:16 / DE:ab 16</certification>
<id>11111111111111111111</id>
<ids>
<entry>
<key>tmdbId</key>
<value xsi:type="xs:int">1111111111</value>
</entry>
<entry>
<key>imdbId</key>
<value xsi:type="xs:string">1111111111</value>
</entry>
</ids>
<watched>true</watched>
<playcount>1</playcount>
</movie>
FIX:
It all comes down to the two attributes:
If i remove
xsi:type="xs:int"
and
xsi:type="xstring"
the .nfo file can be read by TMM again.
TMM error:
Quote:20:18:17.037 ERROR o.t.core.movie.connector.MovieToXbmcNfoConnector - getData
java.lang.IllegalArgumentException: prefix xs is not bound to a namespace
at com.sun.xml.internal.bind.DatatypeConverterImpl._parseQName(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.XsiTypeLoader.parseXsiType(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.XsiTypeLoader.startElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallingContext._startElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallingContext.startElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.SAXConnector.startElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.scanStartElement(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source) ~[na:1.8.0_25]
at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal0(Unknown Source) ~[na:1.8.0_25]
at com.sun.xml.internal.bind.v2.runtime.unmarshaller.UnmarshallerImpl.unmarshal(Unknown Source) ~[na:1.8.0_25]
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(Unknown Source) ~[na:1.8.0_25]
at javax.xml.bind.helpers.AbstractUnmarshallerImpl.unmarshal(Unknown Source) ~[na:1.8.0_25]
at org.tinymediamanager.core.movie.connector.MovieToXbmcNfoConnector.parseNFO(MovieToXbmcNfoConnector.java:726) ~[tmm.jar:2.6.4 (r1770)]
at org.tinymediamanager.core.movie.connector.MovieToXbmcNfoConnector.getData(MovieToXbmcNfoConnector.java:543) ~[tmm.jar:2.6.4 (r1770)]
at org.tinymediamanager.core.movie.tasks.MovieUpdateDatasourceTask.parseMovieDirectory(MovieUpdateDatasourceTask.java:400) [tmm.jar:2.6.4 (r1770)]
at org.tinymediamanager.core.movie.tasks.MovieUpdateDatasourceTask.access$100(MovieUpdateDatasourceTask.java:67) [tmm.jar:2.6.4 (r1770)]
at org.tinymediamanager.core.movie.tasks.MovieUpdateDatasourceTask$FindMovieTask.call(MovieUpdateDatasourceTask.java:881) [tmm.jar:2.6.4 (r1770)]
at org.tinymediamanager.core.movie.tasks.MovieUpdateDatasourceTask$FindMovieTask.call(MovieUpdateDatasourceTask.java:853) [tmm.jar:2.6.4 (r1770)]
at java.util.concurrent.FutureTask.run(Unknown Source) [na:1.8.0_25]
at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [na:1.8.0_25]
at java.util.concurrent.FutureTask.run(Unknown Source) [na:1.8.0_25]
at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [na:1.8.0_25]
at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [na:1.8.0_25]
at java.lang.Thread.run(Unknown Source) [na:1.8.0_25]
Thanks
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - mlaggner - 2014-12-15
Hi,
thanks for the info. I'll put a workaround in the next version
Manuel
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2014-12-15
Great, thank you!
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2014-12-18
Hey there again,
just out of interest, will there be a last version pushed out within this year which contains the workaround?
No hurry!
Thanks.
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - mlaggner - 2014-12-18
I hope so
till XMAS we have very little time (work & family), but I hope I have some more time after XMAS to work on tmm
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2014-12-19
Alright, thanks. Take the time you need. Merry XMAS.
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2015-01-02
Hey there,
just tried the pre-release, reinitialized the database and still getting many .nfo which can't be read. Possibly because of the thing we talked about here.
Question: Is the fix in the 2.6.5 prerelease? Or am i trying too soon?
Will provide more info.
Follow up:
Just tried removing the two attributes like mentioned in my initial post. - and tada - works again.
So it seems that if there is a possible fix in 2.6.5, it doesn't seem to work?
Thanks anyway, we will sort this out! No hurry!
Let me know if you need more info.
Essentially everything i tested some minutes ago is still the same as what i described in my first post.
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - mlaggner - 2015-01-03
You are right - the fix I've included was not good enough. in the next prerelease there will be a (hopefully) working fix
stay tuned
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2015-01-03
Thanks! I'll report back.
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2015-01-05
Quick feedback. Updated last night and although i only did a short test, it seems to work now! Thanks
RE: TMM can't re-read .nfo files altered by "NFO Watchedstate Updater" - axbmcuser - 2015-01-08
Still looking good. Did some more tests.
|