Author: hobbes1069
Update of /cvs/free/rpms/mythtv/devel
In directory old02.ovh.rpmfusion.lan:/tmp/cvs-serv31548
Added Files:
mythtv-0.26-fixes.patch
Log Message:
Add fixes patch.
mythtv-0.26-fixes.patch:
README.rst | 1
mythplugins/mytharchive/i18n/mytharchive_es_es.qm |binary
mythplugins/mytharchive/i18n/mytharchive_es_es.ts | 45
mythplugins/mythgallery/i18n/mythgallery_es_es.ts | 4
mythplugins/mythgame/i18n/mythgame_es_es.ts | 4
mythplugins/mythmusic/i18n/mythmusic_es_es.ts | 68
mythplugins/mythmusic/i18n/mythmusic_it.qm |binary
mythplugins/mythmusic/i18n/mythmusic_it.ts | 3790
+++++++---
mythplugins/mythweather/i18n/mythweather_es_es.qm |binary
mythplugins/mythweather/i18n/mythweather_es_es.ts | 3
mythplugins/mythweather/i18n/mythweather_pl.qm |binary
mythplugins/mythweather/i18n/mythweather_pl.ts | 3
mythtv/bindings/python/MythTV/altdict.py | 2
mythtv/bindings/python/MythTV/dataheap.py | 58
mythtv/bindings/python/MythTV/system.py | 4
mythtv/contrib/imports/mirobridge/mirobridge.py | 96
mythtv/i18n/mythfrontend_es_es.qm |binary
mythtv/i18n/mythfrontend_es_es.ts | 2180 +++--
mythtv/i18n/mythfrontend_pl.qm |binary
mythtv/i18n/mythfrontend_pl.ts | 2733
+++----
mythtv/libs/libmyth/mythcontext.cpp | 2
mythtv/libs/libmythbase/signalhandling.cpp | 8
mythtv/libs/libmythtv/ThreadedFileWriter.cpp | 2
mythtv/libs/libmythtv/mythplayer.cpp | 4
mythtv/libs/libmythui/mythscreenstack.cpp | 2
mythtv/libs/libmythui/mythuiimage.cpp | 3
mythtv/libs/libmythui/mythuitype.cpp | 7
mythtv/libs/libmythui/mythuiwebbrowser.cpp | 10
mythtv/programs/mythavtest/main.cpp | 5
mythtv/programs/mythbackend/main.cpp | 5
mythtv/programs/mythbackend/main_helpers.cpp | 4
mythtv/programs/mythbackend/mainserver.cpp | 16
mythtv/programs/mythccextractor/main.cpp | 5
mythtv/programs/mythcommflag/main.cpp | 5
mythtv/programs/mythfilldatabase/main.cpp | 5
mythtv/programs/mythfrontend/guidegrid.cpp | 17
mythtv/programs/mythfrontend/main.cpp | 5
mythtv/programs/mythjobqueue/main.cpp | 5
mythtv/programs/mythlcdserver/main.cpp | 5
mythtv/programs/mythlogserver/main.cpp | 5
mythtv/programs/mythmediaserver/main.cpp | 5
mythtv/programs/mythmetadatalookup/main.cpp | 5
mythtv/programs/mythpreviewgen/main.cpp | 5
mythtv/programs/mythshutdown/main.cpp | 5
mythtv/programs/mythtranscode/main.cpp | 5
mythtv/programs/mythtv-setup/backendsettings.cpp | 6
mythtv/programs/mythtv-setup/main.cpp | 5
mythtv/programs/mythutil/main.cpp | 6
mythtv/programs/mythwelcome/main.cpp | 5
mythtv/programs/scripts/hardwareprofile/distros/mythtv_data/data_mythtv.py | 20
mythtv/programs/scripts/metadata/Movie/tmdb3.py | 103
51 files changed, 5902 insertions(+), 3379 deletions(-)
--- NEW FILE mythtv-0.26-fixes.patch ---
README.rst | 1 +
mythplugins/mytharchive/i18n/mytharchive_es_es.qm | Bin 36188 -> 36136 bytes
mythplugins/mytharchive/i18n/mytharchive_es_es.ts | 45 +-
mythplugins/mythgallery/i18n/mythgallery_es_es.ts | 4 +-
mythplugins/mythgame/i18n/mythgame_es_es.ts | 4 +-
mythplugins/mythmusic/i18n/mythmusic_es_es.ts | 68 +-
mythplugins/mythmusic/i18n/mythmusic_it.qm | Bin 55341 -> 67158 bytes
mythplugins/mythmusic/i18n/mythmusic_it.ts | 3790 +++++++++++++++-----
mythplugins/mythweather/i18n/mythweather_es_es.qm | Bin 23630 -> 23631 bytes
mythplugins/mythweather/i18n/mythweather_es_es.ts | 3 +-
mythplugins/mythweather/i18n/mythweather_pl.qm | Bin 23846 -> 23847 bytes
mythplugins/mythweather/i18n/mythweather_pl.ts | 3 +-
mythtv/bindings/python/MythTV/altdict.py | 2 +-
mythtv/bindings/python/MythTV/dataheap.py | 58 +-
mythtv/bindings/python/MythTV/system.py | 4 +-
mythtv/contrib/imports/mirobridge/mirobridge.py | 96 +-
mythtv/i18n/mythfrontend_es_es.qm | Bin 669897 -> 672530 bytes
mythtv/i18n/mythfrontend_es_es.ts | 2180 ++++++------
mythtv/i18n/mythfrontend_pl.qm | Bin 350611 -> 354449 bytes
mythtv/i18n/mythfrontend_pl.ts | 2733 ++++++++-------
mythtv/libs/libmyth/mythcontext.cpp | 2 +-
mythtv/libs/libmythbase/signalhandling.cpp | 8 +-
mythtv/libs/libmythtv/ThreadedFileWriter.cpp | 2 +-
mythtv/libs/libmythtv/mythplayer.cpp | 4 +-
mythtv/libs/libmythui/mythscreenstack.cpp | 2 +-
mythtv/libs/libmythui/mythuiimage.cpp | 3 +-
mythtv/libs/libmythui/mythuitype.cpp | 7 +-
mythtv/libs/libmythui/mythuiwebbrowser.cpp | 10 +-
mythtv/programs/mythavtest/main.cpp | 5 +-
mythtv/programs/mythbackend/main.cpp | 5 +-
mythtv/programs/mythbackend/main_helpers.cpp | 4 +-
mythtv/programs/mythbackend/mainserver.cpp | 16 +-
mythtv/programs/mythccextractor/main.cpp | 5 +-
mythtv/programs/mythcommflag/main.cpp | 5 +-
mythtv/programs/mythfilldatabase/main.cpp | 5 +-
mythtv/programs/mythfrontend/guidegrid.cpp | 17 +-
mythtv/programs/mythfrontend/main.cpp | 5 +-
mythtv/programs/mythjobqueue/main.cpp | 5 +-
mythtv/programs/mythlcdserver/main.cpp | 5 +-
mythtv/programs/mythlogserver/main.cpp | 5 +-
mythtv/programs/mythmediaserver/main.cpp | 5 +-
mythtv/programs/mythmetadatalookup/main.cpp | 5 +-
mythtv/programs/mythpreviewgen/main.cpp | 5 +-
mythtv/programs/mythshutdown/main.cpp | 5 +-
mythtv/programs/mythtranscode/main.cpp | 5 +-
mythtv/programs/mythtv-setup/backendsettings.cpp | 6 +-
mythtv/programs/mythtv-setup/main.cpp | 5 +-
mythtv/programs/mythutil/main.cpp | 6 +-
mythtv/programs/mythwelcome/main.cpp | 5 +-
.../distros/mythtv_data/data_mythtv.py | 20 +-
mythtv/programs/scripts/metadata/Movie/tmdb3.py | 103 +-
51 files changed, 5902 insertions(+), 3379 deletions(-)
diff --git a/README.rst b/README.rst
index a151d89..576e0dc 100644
--- a/README.rst
+++ b/README.rst
@@ -20,3 +20,4 @@ Useful project links
- `Mailing lists <
http://www.mythtv.org/mailman/listinfo>`_
- `IRC <
irc://freenode.net/mythtv-users>`_ at
Freenode.net, #mythtv-users
+
diff --git a/mythplugins/mytharchive/i18n/mytharchive_es_es.qm
b/mythplugins/mytharchive/i18n/mytharchive_es_es.qm
index 362945a..9bc0687 100644
Binary files a/mythplugins/mytharchive/i18n/mytharchive_es_es.qm and
b/mythplugins/mytharchive/i18n/mytharchive_es_es.qm differ
diff --git a/mythplugins/mytharchive/i18n/mytharchive_es_es.ts
b/mythplugins/mytharchive/i18n/mytharchive_es_es.ts
index 51f654c..9387d6d 100644
--- a/mythplugins/mytharchive/i18n/mytharchive_es_es.ts
+++ b/mythplugins/mytharchive/i18n/mytharchive_es_es.ts
@@ -829,7 +829,7 @@ Por Favor, Espere...</translation>
<translation>el título va aquí</translation>
</message>
<message>
- <location filename="themestrings.h" line="94"/>
+ <location filename="themestrings.h" line="93"/>
<source>x.xx Gb</source>
<translation>x,xx Gb</translation>
</message>
@@ -1209,52 +1209,47 @@ Por Favor, Espere...</translation>
<translation>x,xx GB</translation>
</message>
<message>
- <location filename="themestrings.h" line="93"/>
- <source>Ok</source>
- <translation>Aceptar</translation>
- </message>
- <message>
- <location filename="themestrings.h" line="95"/>
+ <location filename="themestrings.h" line="94"/>
<source>Select Destination:</source>
<translation>Seleccionar Destino:</translation>
</message>
<message>
- <location filename="themestrings.h" line="96"/>
+ <location filename="themestrings.h" line="95"/>
<source>Parental level: %1</source>
<translation>Nivel parental: %1</translation>
</message>
<message>
- <location filename="themestrings.h" line="97"/>
+ <location filename="themestrings.h" line="96"/>
<source>Old size:</source>
<translation>Tamaño anterior:</translation>
</message>
<message>
- <location filename="themestrings.h" line="98"/>
+ <location filename="themestrings.h" line="97"/>
<source>New size:</source>
<translation>Tamaño nuevo:</translation>
</message>
<message>
- <location filename="themestrings.h" line="99"/>
+ <location filename="themestrings.h" line="98"/>
<source>Select a theme:</source>
<translation>Seleccione un tema:</translation>
</message>
<message>
- <location filename="themestrings.h" line="100"/>
+ <location filename="themestrings.h" line="99"/>
<source>Menu</source>
<translation>Menú</translation>
</message>
<message>
- <location filename="themestrings.h" line="101"/>
+ <location filename="themestrings.h" line="100"/>
<source>Chapter</source>
<translation>Capítulo</translation>
</message>
<message>
- <location filename="themestrings.h" line="102"/>
+ <location filename="themestrings.h" line="101"/>
<source>Detail</source>
<translation>Detalles</translation>
</message>
<message>
- <location filename="themestrings.h" line="103"/>
+ <location filename="themestrings.h" line="102"/>
<source>Select File to Import</source>
<translation>Seleccionar Archivo a Importar</translation>
</message>
@@ -1264,52 +1259,52 @@ Por Favor, Espere...</translation>
<translation>Añadir vídeo</translation>
</message>
<message>
- <location filename="themestrings.h" line="104"/>
+ <location filename="themestrings.h" line="103"/>
<source>Channel ID:</source>
<translation>ID de Canal:</translation>
</message>
<message>
- <location filename="themestrings.h" line="105"/>
+ <location filename="themestrings.h" line="104"/>
<source>Channel Number:</source>
<translation>Número de Canal:</translation>
</message>
<message>
- <location filename="themestrings.h" line="106"/>
+ <location filename="themestrings.h" line="105"/>
<source>Create DVD</source>
<translation>Crear DVD</translation>
</message>
<message>
- <location filename="themestrings.h" line="107"/>
+ <location filename="themestrings.h" line="106"/>
<source>Create Archive</source>
<translation>Crear Archivo</translation>
</message>
<message>
- <location filename="themestrings.h" line="108"/>
+ <location filename="themestrings.h" line="107"/>
<source>Encode Video File</source>
<translation>Codificar Archivo de Vídeo</translation>
</message>
<message>
- <location filename="themestrings.h" line="109"/>
+ <location filename="themestrings.h" line="108"/>
<source>Import Archive</source>
<translation>Importar Archivo</translation>
</message>
<message>
- <location filename="themestrings.h" line="110"/>
+ <location filename="themestrings.h" line="109"/>
<source>Archive Utilities</source>
<translation>Aplicaciones de Archivo</translation>
</message>
<message>
- <location filename="themestrings.h" line="111"/>
+ <location filename="themestrings.h" line="110"/>
<source>Show Log Viewer</source>
<translation>Mostrar Visor del Registro</translation>
</message>
<message>
- <location filename="themestrings.h" line="112"/>
+ <location filename="themestrings.h" line="111"/>
<source>Play Created DVD</source>
<translation>Reproducir el DVD Creado</translation>
</message>
<message>
- <location filename="themestrings.h" line="113"/>
[...20776 lines suppressed...]
diff --git a/mythtv/programs/scripts/metadata/Movie/tmdb3.py
b/mythtv/programs/scripts/metadata/Movie/tmdb3.py
index 6a133f5..853fbe4 100755
--- a/mythtv/programs/scripts/metadata/Movie/tmdb3.py
+++ b/mythtv/programs/scripts/metadata/Movie/tmdb3.py
@@ -11,19 +11,21 @@
#-----------------------
__title__ = "TheMovieDB.org V3"
__author__ = "Raymond Wagner"
-__version__ = "0.3.0"
+__version__ = "0.3.2"
# 0.1.0 Initial version
# 0.2.0 Add language support, move cache to home directory
# 0.3.0 Enable version detection to allow use in MythTV
-
-from MythTV.tmdb3 import searchMovie, Movie, Collection, set_key, set_cache, set_locale
-from MythTV import VideoMetadata
+# 0.3.1 Add --test parameter for proper compatibility with mythmetadatalookup
+# 0.3.2 Add --area parameter to allow country selection for release date and
+# parental ratings
from optparse import OptionParser
-from lxml import etree
import sys
-def buildSingle(inetref):
+def buildSingle(inetref, opts):
+ from MythTV.tmdb3 import Movie
+ from MythTV import VideoMetadata
+ from lxml import etree
movie = Movie(inetref)
tree = etree.XML(u'<metadata></metadata>')
mapping = [['runtime', 'runtime'], ['title',
'originaltitle'],
@@ -35,12 +37,30 @@ def buildSingle(inetref):
for i,j in mapping:
if getattr(movie, j):
setattr(m, i, getattr(movie, j))
+
+ releases = movie.releases.items()
+
+ if opts.country:
+ for alt in movie.alternate_titles:
+ if alt.country == opts.country:
+ m.title = alt.title
+ break
+ try:
+ # resort releases with selected country at top to ensure it
+ # is selected by the metadata libraries
+ index = zip(*releases)[0].index(opts.country)
+ releases.insert(0, releases.pop(index))
+ except ValueError:
+ pass
+ else:
+ m.releasedate = releases[0][1].releasedate
+
m.inetref = str(movie.id)
- if movie.releasedate:
- m.year = movie.releasedate.year
if movie.collection:
m.collectionref = str(movie.collection.id)
- for country, release in movie.releases.items():
+ if movie.releasedate:
+ m.year = movie.releasedate.year
+ for country, release in releases:
if release.certification:
m.certifications[country] = release.certification
for genre in movie.genres:
@@ -70,11 +90,15 @@ def buildSingle(inetref):
xml_declaration=True))
sys.exit()
-def buildList(query):
+def buildList(query, opts):
# TEMPORARY FIX:
# replace all dashes from queries to work around search behavior
# as negative to all text that comes afterwards
query = query.replace('-',' ')
+
+ from MythTV.tmdb3 import searchMovie
+ from MythTV import VideoMetadata
+ from lxml import etree
results = searchMovie(query)
tree = etree.XML(u'<metadata></metadata>')
mapping = [['runtime', 'runtime'], ['title',
'originaltitle'],
@@ -89,6 +113,10 @@ def buildList(query):
if getattr(res, j):
setattr(m, i, getattr(res, j))
m.inetref = str(res.id)
+ #TODO:
+ # should releasedate and year be pulled from the country-specific data
+ # or should it be left to the default information to cut down on
+ # traffic from searches
if res.releasedate:
m.year = res.releasedate.year
if res.backdrop:
@@ -109,7 +137,10 @@ def buildList(query):
xml_declaration=True))
sys.exit(0)
-def buildCollection(inetref):
+def buildCollection(inetref, opts):
+ from MythTV.tmdb3 import Collection
+ from MythTV import VideoMetadata
+ from lxml import etree
collection = Collection(inetref)
tree = etree.XML(u'<metadata></metadata>')
m = VideoMetadata()
@@ -129,6 +160,7 @@ def buildCollection(inetref):
sys.exit()
def buildVersion():
+ from lxml import etree
version = etree.XML(u'<grabber></grabber>')
etree.SubElement(version, "name").text = __title__
etree.SubElement(version, "author").text = __author__
@@ -142,43 +174,78 @@ def buildVersion():
xml_declaration=True))
sys.exit(0)
-def main():
- set_key('c27cb71cff5bd76e1a7a009380562c62')
- set_cache(engine='file', filename='~/.mythtv/pytmdb3.cache')
+def performSelfTest():
+ err = 0
+ try:
+ import MythTV
+ except:
+ err = 1
+ print ("Failed to import MythTV bindings. Check your `configure` output
"
+ "to make sure installation was not disabled due to external "
+ "dependencies")
+ try:
+ import MythTV.tmdb3
+ except:
+ err = 1
+ print ("Failed to import PyTMDB3 library. This should have been included
"
+ "with the python MythTV bindings.")
+ try:
+ import lxml
+ except:
+ err = 1
+ print "Failed to import python lxml library."
+
+ if not err:
+ print "Everything appears in order."
+ sys.exit(err)
+def main():
parser = OptionParser()
parser.add_option('-v', "--version", action="store_true",
default=False,
dest="version", help="Display version and
author")
+ parser.add_option('-t', "--test", action="store_true",
default=False,
+ dest="test", help="Perform self-test for
dependencies.")
parser.add_option('-M', "--movielist",
action="store_true", default=False,
dest="movielist", help="Get Movies matching
search.")
parser.add_option('-D', "--moviedata",
action="store_true", default=False,
dest="moviedata", help="Get Movie data.")
parser.add_option('-C', "--collection",
action="store_true", default=False,
dest="collectiondata", help="Get Collection
data.")
- parser.add_option( "-l", "--language",
metavar="LANGUAGE", default=u'en',
+ parser.add_option('-l', "--language", metavar="LANGUAGE",
default=u'en',
dest="language", help="Specify language for
filtering.")
+ parser.add_option('-a', "--area", metavar="COUNTRY",
default=None,
+ dest="country", help="Specify country for custom
data.")
opts, args = parser.parse_args()
if opts.version:
buildVersion()
+ if opts.test:
+ performSelfTest()
+
+ from MythTV.tmdb3 import set_key, set_cache, set_locale
+ set_key('c27cb71cff5bd76e1a7a009380562c62')
+ set_cache(engine='file', filename='~/.mythtv/pytmdb3.cache')
+
if opts.language:
set_locale(language=opts.language, fallthrough=True)
+ if opts.country:
+ set_locale(country=opts.country, fallthrough=True)
if (len(args) != 1) or (args[0] == ''):
sys.stdout.write('ERROR: tmdb3.py requires exactly one non-empty
argument')
sys.exit(1)
if opts.movielist:
- buildList(args[0])
+ buildList(args[0], opts)
if opts.moviedata:
- buildSingle(args[0])
+ buildSingle(args[0], opts)
if opts.collectiondata:
- buildCollection(args[0])
+ buildCollection(args[0], opts)
if __name__ == '__main__':
main()