A community-supported supercharged document management system: scan, index and archive all your documents
Python aiangulararchivingdjangodmsdocument-managementdocument-management-systemllmmachine-learningocroptical-character-recognitionpdf
break long lines (pep8)
ishirav4c38b28469c8
diff --git a/src/documents/models.py b/src/documents/models.pyindex ee6ee8d31..8021e03c1 100644--- a/src/documents/models.py+++ b/src/documents/models.py@@ -132,7 +132,8 @@ class MatchingModel(models.Model):'''findterms = re.compile(r'"([^"]+)"|(\S+)').findallnormspace = re.compile(r'\s+').sub- return [normspace(r'\s+', (t[0] or t[1]).strip()) for t in findterms(self.match)]+ return [normspace(r'\s+', (t[0] or t[1]).strip())+ for t in findterms(self.match)]def save(self, *args, **kwargs):diff --git a/src/documents/tests/test_matchables.py b/src/documents/tests/test_matchables.pyindex 6e64fc5bf..b1b8eb46f 100644--- a/src/documents/tests/test_matchables.py+++ b/src/documents/tests/test_matchables.py@@ -16,9 +16,11 @@ class TestMatching(TestCase):matching_algorithm=getattr(klass, algorithm))for string in true:- self.assertTrue(instance.matches(string), '"%s" should match "%s" but it does not' % (text, string))+ self.assertTrue(instance.matches(string),+ '"%s" should match "%s" but it does not' % (text, string))for string in false:- self.assertFalse(instance.matches(string), '"%s" should not match "%s" but it does' % (text, string))+ self.assertFalse(instance.matches(string),+ '"%s" should not match "%s" but it does' % (text, string))def test_match_all(self):