Skip to content

Commit

Permalink
wip: use print without access to sys
Browse files Browse the repository at this point in the history
  • Loading branch information
yowpark committed Oct 26, 2023
1 parent 874368c commit 5110a16
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions client/python/gamium/gamium/internal/logger.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
import sys

class Logger:
def __init__(self):
self._printable = ConsolePrintable()
Expand Down Expand Up @@ -28,12 +26,10 @@ def verbose(self, message):
self._printable.verbose(message)

def dot(self):
sys.stdout.write(".")
sys.stdout.flush()
print(".", end="", flush=True)

def newline(self):
sys.stdout.write("\n")
sys.stdout.flush()
print("", end="\n", flush=True)


class ConsolePrintable:
Expand All @@ -54,3 +50,4 @@ def debug(self, message):

def verbose(self, message):
print(f"VERBOSE: {message}")

0 comments on commit 5110a16

Please sign in to comment.