Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Allow bad Metadata tags to be bypassed

This is in response to a change in the TMDb API that resulted in the
grabber returning bad data for the 'lastupdated' field.  If a field
returns bad data, skip over it and continue processing the rest of the
result.

(cherry picked from commit 15b0ffc)
  • Loading branch information...
commit 19a63d462aa8614851062f2681ba97d0eff357c6 1 parent fdfc989
@wagnerrp wagnerrp authored
Showing with 12 additions and 10 deletions.
  1. +12 −10 mythtv/bindings/python/MythTV/system.py
View
22 mythtv/bindings/python/MythTV/system.py
@@ -147,16 +147,18 @@ def _fillNone(self):
def _process(self, xml):
for element in xml.getchildren():
- if element.tag in self:
- if (element.text == '') or (element.text is None):
- self[element.tag] = None
- else:
- self[element.tag] = \
- self._trans[self._global_type[element.tag]]\
- (element.text)
- if element.tag in self._groups:
- self.__dict__[element.tag] = \
- eval('self.%s(element)' % element.tag.capitalize())
+ try:
+ if element.tag in self:
+ if (element.text == '') or (element.text is None):
+ self[element.tag] = None
+ else:
+ self[element.tag] = \
+ self._trans[self._global_type[element.tag]]\
+ (element.text)
+ if element.tag in self._groups:
+ self.__dict__[element.tag] = \
+ eval('self.%s(element)' % element.tag.capitalize())
+ except: pass
class VideoMetadata( Metadata ):
_field_order = ['title','subtitle','tagline','description','season',
Please sign in to comment.
Something went wrong with that request. Please try again.