Name the line of a non-UTF-8 README.md
This commit is contained in:
+1
-1
@@ -166,7 +166,7 @@ def read_premises(root):
|
||||
except OSError as failure:
|
||||
sys.exit(f"README.md in {root}: {failure.strerror} - no premises.")
|
||||
except UnicodeDecodeError as failure:
|
||||
sys.exit(f"README.md is not UTF-8 at byte {failure.start} - no premises.")
|
||||
sys.exit(f"README.md is not UTF-8 on line {failure.object[:failure.start].count(b'\n') + 1} - no premises.")
|
||||
for name in ("Goals", "Audience"):
|
||||
bodies = found.get(name, [])
|
||||
if not bodies:
|
||||
|
||||
Reference in New Issue
Block a user