aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorNick Mathewson <nickm@torproject.org>2003-05-20 19:27:49 +0000
committerNick Mathewson <nickm@torproject.org>2003-05-20 19:27:49 +0000
commit77f42c5cb89d81ff3010614408d1fa814e320f9a (patch)
tree6a970dece7d8f328aef9533687cf05488d7cc44f
parent490a8953e95bda04d116d0b2265f7247b0af840b (diff)
downloadanonbib-77f42c5cb89d81ff3010614408d1fa814e320f9a.tar.gz
Catch extraneous periods
svn:r21
-rw-r--r--BibTeX.py7
1 files changed, 5 insertions, 2 deletions
diff --git a/BibTeX.py b/BibTeX.py
index 92bef24..ee2dd12 100644
--- a/BibTeX.py
+++ b/BibTeX.py
@@ -261,10 +261,13 @@ class BibTeXEntry:
if not self['booktitle'].startswith("Proceedings of"):
errs.append("ERROR: %s's booktitle doesn't start with 'Proceedings'" % self.key)
-
- for field in self.entries.keys():
+ for field, value in self.entries.items():
if field.startswith("www_") and field not in WWW_FIELDS:
errs.append("ERROR: unknown www field %s"% field)
+ if value.strip()[-1:] == '.' and \
+ field not in ("notes", "www_remarks"):
+ errs.append("ERROR: %s.%s has an extraneous period"%(self.key,
+ field))
return errs
def biblio_to_html(self):