enthought / envisage

Envisage is a Python-based framework for building applications whose functionalities can be extended by adding "plug-ins".
http://docs.enthought.com/envisage/
Other
82 stars 26 forks source link

Should we provide a LazyTaskAction? #395

Open aaronayres35 opened 3 years ago

aaronayres35 commented 3 years ago

Related to #394

In some cases, one plugin may contribute actions that reference a task contributed by a different plugin. In cases like these, care needs to be taken so that those actions don't try to access or reference that Task before it exists.

We could define a subclass of TaskAction called LazyTaskAction which waits until someone tries to access the task to define. This class could make use of the get_task method on the application as mentioned in #394