Skip to content

Commit

Permalink
removed spinner loading
Browse files Browse the repository at this point in the history
  • Loading branch information
joamag committed Apr 17, 2018
1 parent 7bfebba commit 801f3aa
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions src/appier_console/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -212,9 +212,11 @@ def run(self):
self._condition.wait(interval)
self._condition.release()

# verifies if the current context should end with a new line
# or if instead the same line is going to be re-used and write
# the appropriate string sequence to the output stream
if self.end_newline: self.stream.write("\n")
else: self.stream.write(CLEAR_LINE + "\r")

self.stream.flush()

def stop(self):
Expand All @@ -236,7 +238,9 @@ def interval_g(self):

@property
def has_spinner(self):
return self.is_tty
if not self.is_tty: return False
if os.name in ("nt",) and not appier.legacy.PYTHON_3: return False
return True

@property
def is_tty(self):
Expand Down

0 comments on commit 801f3aa

Please sign in to comment.