musicbrainz/picard — pull request #345 by phw (2014-06-22 18:17:45+00:00)
Title: Fix evaluation of script functions with zero arguments.

This fixes the evaluation of script functions with zero arguments (that is the Python function does not take any additional argument despite the `parser`argument).

An example of such a function would be:
```
def is_video(parser):
"""Returns true, if the file processed is a video file."""
if parser.context['~extension'] in ['m4v', 'wmv', 'ogv', 'oggtheora']:
return "1"
else:
return ""
```

Without the fix the evaluation of that function will fail with `picard.script.ScriptError: Wrong number of arguments for $is_video: Expected 0 - 0, got 1 at position 25, line 2`.