Initial structure of per-scope constraint.
Next part of scope validation in the graph.
Add some on-create module validation to ensure that modules can't have invalid specification of scopes on them.
Implement mixed scope test.
Fix up some scope validation.