Skip to content

Commit 34b4a3a

Browse files
authored
Merge pull request #186 from openatx/fix-patch-1
fix patch 1
2 parents 5733f2a + 89b1269 commit 34b4a3a

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

adbutils/_utils.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@ def update(self, chunk: bytes):
184184

185185
copysize = humanize(self.copied)
186186
totalsize = humanize(self.total)
187-
if sys.stdout.isatty():
187+
if hasattr(sys.stdout, 'isatty') and sys.stdout.isatty():
188188
print("{:.1f}%\t{} [{}/{}]".format(percent, speed, copysize,
189189
totalsize))
190190

0 commit comments

Comments
 (0)