Require task class only in backend context