Add more typing.
Fix publishing bug.