lots of cleanup

- docstring for main
- fix scoping issue
- no need to raise ValueError - optparts does that
- fix subdomains
- mdui:DomainHint isn't language-taged
- lots more test-cases