stubtest_stdlib: fail if there are unused allowlist entries (#6424)

Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Akuli
2021-12-01 12:10:27 +02:00
committed by GitHub
parent deaa764915
commit bdf906e2bc
6 changed files with 4 additions and 117 deletions

View File

@@ -57,7 +57,8 @@ def run_stubtest(typeshed_dir: Path) -> int:
"\nCommand run was: {}\n".format(" ".join(cmd)),
file=sys.stderr,
)
print("stubtest failed", file=sys.stderr)
print("\n\n", file=sys.stderr)
print(f'To fix "unused allowlist" errors, remove the corresponding entries from {allowlist_dir}', file=sys.stderr)
return e.returncode
else:
print("stubtest succeeded", file=sys.stderr)