You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@lucene.apache.org by mi...@apache.org on 2014/10/03 11:20:10 UTC
svn commit: r1629157 - /lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py
Author: mikemccand
Date: Fri Oct 3 09:20:09 2014
New Revision: 1629157
URL: http://svn.apache.org/r1629157
Log:
improve error reporting when this tool finds javadocs problems
Modified:
lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py
Modified: lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py
URL: http://svn.apache.org/viewvc/lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py?rev=1629157&r1=1629156&r2=1629157&view=diff
==============================================================================
--- lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py (original)
+++ lucene/dev/trunk/dev-tools/scripts/checkJavaDocs.py Fri Oct 3 09:20:09 2014
@@ -161,9 +161,11 @@ def checkClassSummaries(fullPath):
foundMethodDetail = False
lastMethodAnchor = None
+ lineCount = 0
for line in f.readlines():
m = reMethodDetail.search(line)
+ lineCount += 1
if m is not None:
foundMethodDetail = True
continue
@@ -212,6 +214,8 @@ def checkClassSummaries(fullPath):
if inThing:
if lineLower.find('</tr>') != -1:
if not hasDesc:
+ if lastItem is None:
+ raise RuntimeError('failed to locate javadoc item in %s, line %d? last line: %s' % (fullPath, lineCount, line.rstrip()))
missing.append((lastCaption, unEscapeURL(lastItem)))
inThing = False
continue