Formatting fixes.
Revamp documentation and cleanup file layout.
Serializing a ScriptOp should result in a byte string, not a ScriptOp value.
Performing Script().join(…) should result in a Script object, but doesn’t due to unfortunate Python language / standard library design. Therefore, explicitly cast the result.
Some JSON-RPC commands which have no return type set ‘response’ to None, and that is okay.
Move imports to the bottom of core.py, so as to resolve circular import dependencies.