With agreement from @attrc and @imhlv2, I'm removing the useless
validate method from the object. It defaulted to returning inaccurate
information (validity undetermined, but validate returned True as if
validation had happened) and is better handled by individual classes
implementing is_valid (which seems the preferred nomenclature) and
throwing exceptions if it's called on a class that doesn't have it.
Consider revisiting this at some point, it immediately throws an
exception, so should cause significant slow downs (none detected on a
reasonably fast machine, although buildbot will give a better idea).
Without this a lot more specific typing will be required on the
expectation that Structs will be returned rather than any other type of
object.
This removes the assertions that checked plugin devs didn't do anything
overly bad in favour of using mypy to ensure appropriate type-checking.
It also moves the ProgressCallback typing information to constants in
order to avoid circular imports (since constants doesn't import
anything).
Relented on the strict import of direct objects/classes for the typing
module only. Typing module components can be directly imported because
it makes the code really painful to read and write otherwise.
This is still in-line with the python style guide adopted from Google at
http://google.github.io/styleguide/pyguide.html section 2.2.
This template type allows objects that have not been able to be resolved
to exist within the symbol system. It emits a debug message on creation
so that intermediate format developers can identify potential issues,
but does not raise an exception so as to allow partial tables to be
used.
If the UnresolvedTemplate is called (to create an object) before the
symbol has been added to the symbolspace, it will fail with a
SymbolError (as thrown by the individual SymbolTable). For this reason,
the class has been made private to the SymbolSpace class to prevent
unexpected use.