sampsyo/beets — pull request #1186 by mried (2014-12-29 10:51:00+00:00)
Title: Added a file filter based on regular expressions

The file filter is included within the ihate plugin and uses the new `import_task_created` event which is fired for each task after it is created.
The plugin is only a first approach. Maybe the plugin rules are much to complicated. I'm not even sure if I'll use them for my own library...
A new pipeline stage is used to fire the event so the code to be changed is limited to one place.

Note: Running `tox -e py27cov` or even `nose` on my windows box lets fail all the new tests of `test_ihate`:
```
beets: WARNING: ** error loading plugin ihate
beets: WARNING: Traceback (most recent call last):
File "D:\work\beets\beets\beets\plugins.py", line 211, in load_plugins
for obj in getattr(namespace, name).__dict__.values():
AttributeError: 'module' object has no attribute 'ihate'
```
Running the test module without the other modules is working. I found out the the paths in `beetsplug.__path__` are different but couldn't figure out what's leading to the difference nor why one of values leads to failures. Seems I'm at the end of my python knowledge :wink:...