-
Notifications
You must be signed in to change notification settings - Fork 52
Description
📚 Documentation
The plugin contribution guide's reader example includes a code snippet that's made available for copy-and-paste and makes a nice template that could be edited for quick plugin development, but it includes the LayerData type alias that's note explained on the same page, and isn't provided in code.
Following the link on the same page (reader contribution guide) to the page for layer data tuples, we see the type alias explained in the formal type definition. That definition, in turn, contains other type aliases which, while detailed in the code below it on that same page, includes a reference to a Protocol subtype (ArrayLike) that's noted as an approximation rather than a real intended definition.
How is a developer of a reader plugin, then, to type the return value of a get_reader function? It should be Optional[ReaderFunction], but following the path of contained types (ReaderFunction --> LayerData --> DataType --> ArrayLike) leads somewhere to a type (ArrayLike) which isn't clear to what this name concretely refers.
Are these type aliases available somewhere for import? If not, how to proceed with the type signature for a reader plugin?