Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

Re-enabling break scanning for more accurate haiku detection.

  • Loading branch information...
commit 251a6e1f22913a4e2399572de7d956862c004d45 1 parent b41b9d9
@jparise authored
Showing with 5 additions and 5 deletions.
  1. +5 −5 haikufinder/__init__.py
View
10 haikufinder/__init__.py
@@ -214,9 +214,9 @@ def seek(self, n):
if syllable_count > n:
raise Nope
line = ' '.join(self.words[si:self.index])
-# for f in single_line_filters:
-# if f.search(line):
-# raise Nope
+ for f in single_line_filters:
+ if f.search(line):
+ raise Nope
self.lines.append(line)
def seek_eol(self):
@@ -233,8 +233,8 @@ def find_haiku(self):
self.seek_eol()
if first_word_comma.search(self.lines[1]) or first_word_comma.search(self.lines[2]):
raise Nope
-# if break_filter.search('\n'.join(self.lines)):
-# raise Nope
+ if break_filter.search('\n'.join(self.lines)):
+ raise Nope
return self.lines
Please sign in to comment.
Something went wrong with that request. Please try again.