diff --git a/spacy/tokens/doc.pyx b/spacy/tokens/doc.pyx index 2089199a0..ca5a3d696 100644 --- a/spacy/tokens/doc.pyx +++ b/spacy/tokens/doc.pyx @@ -431,7 +431,8 @@ cdef class Doc: """ def __get__(self): if 'sents' in self.user_hooks: - return self.user_hooks['sents'](self) + yield from self.user_hooks['sents'](self) + return if not self.is_parsed: raise ValueError(