Uploaded image for project: 'Picard'
  1. Picard
  2. PICARD-1517

Functions matchedtracks and is_complete throw exception when run on cluster

XMLWordPrintable

      Having the scripting functions is_complete() or matchedtracks() in naming script and saving a cluster causes an exception:

      E: 17:22:37,525 /home/phw/devel/musicbrainz/picard/picard/util/thread.run:56: Traceback (most recent call last):
      File "/home/phw/devel/musicbrainz/picard/picard/util/thread.py", line 52, in run
      result = self.func()
      File "/home/phw/devel/musicbrainz/picard/picard/file.py", line 269, in _save_and_rename
      new_filename = self._rename(old_filename, metadata)
      File "/home/phw/devel/musicbrainz/picard/picard/file.py", line 431, in _rename
      self._make_filename(old_filename, metadata))
      File "/home/phw/devel/musicbrainz/picard/picard/file.py", line 420, in _make_filename
      new_filename = self._format_filename(new_dirname, new_filename, metadata, settings)
      File "/home/phw/devel/musicbrainz/picard/picard/file.py", line 384, in _format_filename
      new_filename = self._script_to_filename(naming_format, metadata, settings)
      File "/home/phw/devel/musicbrainz/picard/picard/file.py", line 364, in _script_to_filename
      return script_to_filename(naming_format, metadata, file=self, settings=settings)
      File "/home/phw/devel/musicbrainz/picard/picard/util/scripttofilename.py", line 41, in script_to_filename
      filename = ScriptParser().eval(naming_format, meta, file)
      File "/home/phw/devel/musicbrainz/picard/picard/script.py", line 294, in eval
      return ScriptParser._cache[key].eval(self)
      File "/home/phw/devel/musicbrainz/picard/picard/script.py", line 133, in eval
      return "".join([item.eval(state) for item in self])
      File "/home/phw/devel/musicbrainz/picard/picard/script.py", line 133, in <listcomp>
      return "".join([item.eval(state) for item in self])
      File "/home/phw/devel/musicbrainz/picard/picard/script.py", line 127, in eval
      return function(parser, *args)
      File "/home/phw/devel/musicbrainz/picard/picard/script.py", line 720, in func_is_complete
      if (file and file.parent and hasattr(file.parent, 'album')
      AttributeError: 'Cluster' object has no attribute 'album'

            outsidecontext Philipp Wolfer
            outsidecontext Philipp Wolfer
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Created:
              Updated:
              Resolved:

                Version Package
                2.2