Merge pull request #1319 from dennishendriksen/master

Annotator: lazy load vars + default encoding fix
Merge pull request #1322 from dennishendriksen/master

Fix annotator tests, refactor classes to make testable
fix attribute selection issue