Lazy load sources

Rebased batman's code onto latest release (Note: not tip of master).
Fixed compatibility issues, and _copy_state_from called on connect vivifying all the sources anyway.