Wire dependencies before context initialization
fix #43
Merge pull request #45 from creynders/fix_43

Wire dependencies before context initialization