Fixed several bugs, removed some assertions, updated the code to match the spec

- Removed some timing-sensitive part (e.g. waiting for msg in oninstall())
- Removed messaging via message.source
- Renamed .active to .current