Only load lib and repo

Also removed attempt to load from function scope as this does not work with
current Wikibase code

Change-Id: I6fdeae73567c22986ae0531436b9c681665bc760
Merge "Only load lib and repo"