Skip to content

Commit

Permalink
Fix warning printing
Browse files Browse the repository at this point in the history
  • Loading branch information
Andi Kleen committed Nov 20, 2023
1 parent 5b320f7 commit f3ca0f6
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tl_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,8 @@
import subprocess
import os
import argparse
if sys.version_info.major == 3:
from typing import Set # noqa

if sys.version_info.major == 3:
popentext = dict(universal_newlines=True)
Expand Down Expand Up @@ -70,7 +72,7 @@ def warn(msg):
if test_mode:
assert 0

warned = argparse.Namespace()
warned = set() # type: Set[str]

def warn_once_no_assert(msg):
if msg not in warned and not args.quiet:
Expand Down

0 comments on commit f3ca0f6

Please sign in to comment.