Skip to content
This repository was archived by the owner on Aug 11, 2020. It is now read-only.

Commit deb58e8

Browse files
committed
Feature PS-9868:
Remove colorclass requirements from CLI because we can use click style function
1 parent ba5ba73 commit deb58e8

File tree

5 files changed

+4
-7
lines changed

5 files changed

+4
-7
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
clean-tests:
22
rm -rf .tox paperspace.egg-info
33

4-
run-tests: clean-tox
4+
run-tests: clean-tests
55
tox

Pipfile

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,6 @@ click = "*"
1515
terminaltables = "*"
1616
click-didyoumean = "*"
1717
click-help-colors = "*"
18-
colorclass = "*"
1918
tox = "*"
2019

2120
[dev-packages]

Pipfile.lock

Lines changed: 1 addition & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

paperspace/commands/logs.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import pydoc
22

33
import terminaltables
4-
from colorclass import Color
4+
from click import style
55

66
from paperspace.commands import CommandBase
77
from paperspace.utils import get_terminal_lines
@@ -55,6 +55,6 @@ def _make_table(self, logs, table, table_data):
5555
self.last_line_number = logs[-1].get("line")
5656

5757
for log in logs:
58-
table_data.append((Color.colorize("red", log.get("line")), log.get("message")))
58+
table_data.append((style(fg="red", text=str(log.get("line"))), log.get("message")))
5959

6060
return table.table

setup.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -50,7 +50,6 @@
5050
'terminaltables',
5151
'click-didyoumean',
5252
'click-help-colors',
53-
'colorclass',
5453
],
5554
extras_require={
5655
':sys_platform == "win32"': [

0 commit comments

Comments
 (0)