progress-table 3.3.2__tar.gz → 3.3.4__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,9 +1,9 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: progress-table
3
- Version: 3.3.2
3
+ Version: 3.3.4
4
4
  Summary: Display progress as a pretty table in the command line.
5
- Project-URL: Home, https://github.com/gahaalt/progress-table
6
- Project-URL: Documentation, https://github.com/sjmikler/progress-table/blob/main/docs
5
+ Project-URL: Home, https://github.com/szmikler/progress-table
6
+ Project-URL: Documentation, https://github.com/szmikler/progress-table/blob/main/docs
7
7
  Author-email: Szymon Mikler <sjmikler@gmail.com>
8
8
  License: MIT
9
9
  License-File: LICENSE.txt
@@ -14,6 +14,7 @@ Classifier: Programming Language :: Python :: 3.11
14
14
  Classifier: Programming Language :: Python :: 3.12
15
15
  Classifier: Programming Language :: Python :: 3.13
16
16
  Classifier: Programming Language :: Python :: 3.14
17
+ Classifier: Typing :: Typed
17
18
  Requires-Python: >=3.10
18
19
  Requires-Dist: colorama
19
20
  Requires-Dist: wcwidth
@@ -29,8 +30,8 @@ Description-Content-Type: text/markdown
29
30
  # Progress Table
30
31
 
31
32
  [![PyPi version](https://img.shields.io/badge/dynamic/json?label=latest&query=info.version&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://pypi.org/project/progress-table)
32
- [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/sjmikler/progress-table/blob/main/LICENSE.txt)
33
- [![codecov](https://codecov.io/gh/sjmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/sjmikler/progress-table)
33
+ [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/szmikler/progress-table/blob/main/LICENSE.txt)
34
+ [![codecov](https://codecov.io/gh/szmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/szmikler/progress-table)
34
35
 
35
36
  Lightweight utility to display the progress of your process as a pretty table in the command line.
36
37
 
@@ -42,11 +43,11 @@ Lightweight utility to display the progress of your process as a pretty table in
42
43
 
43
44
  ### Change this:
44
45
 
45
- ![example](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/progress-before3.gif)
46
+ ![example](https://raw.githubusercontent.com/szmikler/progress-table/main/images/progress-before3.gif)
46
47
 
47
48
  ### Into this:
48
49
 
49
- ![example](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/progress-after4.gif)
50
+ ![example](https://raw.githubusercontent.com/szmikler/progress-table/main/images/progress-after4.gif)
50
51
 
51
52
  ## Examples
52
53
 
@@ -54,19 +55,19 @@ From `examples/` directory:
54
55
 
55
56
  * Neural network training
56
57
 
57
- ![example-training](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-training.gif)
58
+ ![example-training](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-training.gif)
58
59
 
59
60
  * Progress of multi-threaded downloads
60
61
 
61
- ![example-download](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-download.gif)
62
+ ![example-download](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-download.gif)
62
63
 
63
64
  * Simulation and interactive display of Brownian motion
64
65
 
65
- ![example-brown2d](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-brown2d.gif)
66
+ ![example-brown2d](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-brown2d.gif)
66
67
 
67
68
  * Display of a game board
68
69
 
69
- ![example-tictactoe](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-tictactoe.gif)
70
+ ![example-tictactoe](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-tictactoe.gif)
70
71
 
71
72
  ## Quick start code
72
73
 
@@ -107,12 +108,12 @@ table.close()
107
108
 
108
109
  ```
109
110
 
110
- > Go to [integrations](https://github.com/sjmikler/progress-table/blob/main/docs//integrations.md)
111
+ > Go to [integrations](https://github.com/szmikler/progress-table/blob/main/docs//integrations.md)
111
112
  > page to see examples of integration with deep learning libraries.
112
113
 
113
114
  ## Advanced usage
114
115
 
115
- Go to [advanced usage](https://github.com/sjmikler/progress-table/blob/main/docs//advanced-usage.md) page for more information.
116
+ Go to [advanced usage](https://github.com/szmikler/progress-table/blob/main/docs//advanced-usage.md) page for more information.
116
117
 
117
118
  ## Troubleshooting
118
119
 
@@ -140,7 +141,7 @@ pip install progress-table
140
141
 
141
142
  ## Links
142
143
 
143
- * [See on GitHub](https://github.com/gahaalt/progress-table)
144
+ * [See on GitHub](https://github.com/szmikler/progress-table)
144
145
  * [See on PyPI](https://pypi.org/project/progress-table)
145
146
 
146
147
  ## Alternatives
@@ -1,8 +1,8 @@
1
1
  # Progress Table
2
2
 
3
3
  [![PyPi version](https://img.shields.io/badge/dynamic/json?label=latest&query=info.version&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://pypi.org/project/progress-table)
4
- [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/sjmikler/progress-table/blob/main/LICENSE.txt)
5
- [![codecov](https://codecov.io/gh/sjmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/sjmikler/progress-table)
4
+ [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/szmikler/progress-table/blob/main/LICENSE.txt)
5
+ [![codecov](https://codecov.io/gh/szmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/szmikler/progress-table)
6
6
 
7
7
  Lightweight utility to display the progress of your process as a pretty table in the command line.
8
8
 
@@ -112,7 +112,7 @@ pip install progress-table
112
112
 
113
113
  ## Links
114
114
 
115
- * [See on GitHub](https://github.com/gahaalt/progress-table)
115
+ * [See on GitHub](https://github.com/szmikler/progress-table)
116
116
  * [See on PyPI](https://pypi.org/project/progress-table)
117
117
 
118
118
  ## Alternatives
@@ -1,8 +1,8 @@
1
1
  # Progress Table
2
2
 
3
3
  [![PyPi version](https://img.shields.io/badge/dynamic/json?label=latest&query=info.version&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://pypi.org/project/progress-table)
4
- [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/sjmikler/progress-table/blob/main/LICENSE.txt)
5
- [![codecov](https://codecov.io/gh/sjmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/sjmikler/progress-table)
4
+ [![PyPI license](https://img.shields.io/badge/dynamic/json?label=license&query=info.license&url=https%3A%2F%2Fpypi.org%2Fpypi%2Fprogress-table%2Fjson)](https://github.com/szmikler/progress-table/blob/main/LICENSE.txt)
5
+ [![codecov](https://codecov.io/gh/szmikler/progress-table/graph/badge.svg?token=CDJKF0FFAQ)](https://codecov.io/gh/szmikler/progress-table)
6
6
 
7
7
  Lightweight utility to display the progress of your process as a pretty table in the command line.
8
8
 
@@ -14,11 +14,11 @@ Lightweight utility to display the progress of your process as a pretty table in
14
14
 
15
15
  ### Change this:
16
16
 
17
- ![example](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/progress-before3.gif)
17
+ ![example](https://raw.githubusercontent.com/szmikler/progress-table/main/images/progress-before3.gif)
18
18
 
19
19
  ### Into this:
20
20
 
21
- ![example](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/progress-after4.gif)
21
+ ![example](https://raw.githubusercontent.com/szmikler/progress-table/main/images/progress-after4.gif)
22
22
 
23
23
  ## Examples
24
24
 
@@ -26,19 +26,19 @@ From `examples/` directory:
26
26
 
27
27
  * Neural network training
28
28
 
29
- ![example-training](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-training.gif)
29
+ ![example-training](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-training.gif)
30
30
 
31
31
  * Progress of multi-threaded downloads
32
32
 
33
- ![example-download](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-download.gif)
33
+ ![example-download](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-download.gif)
34
34
 
35
35
  * Simulation and interactive display of Brownian motion
36
36
 
37
- ![example-brown2d](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-brown2d.gif)
37
+ ![example-brown2d](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-brown2d.gif)
38
38
 
39
39
  * Display of a game board
40
40
 
41
- ![example-tictactoe](https://raw.githubusercontent.com/sjmikler/progress-table/main/images/examples-tictactoe.gif)
41
+ ![example-tictactoe](https://raw.githubusercontent.com/szmikler/progress-table/main/images/examples-tictactoe.gif)
42
42
 
43
43
  ## Quick start code
44
44
 
@@ -79,12 +79,12 @@ table.close()
79
79
 
80
80
  ```
81
81
 
82
- > Go to [integrations](https://github.com/sjmikler/progress-table/blob/main/docs//integrations.md)
82
+ > Go to [integrations](https://github.com/szmikler/progress-table/blob/main/docs//integrations.md)
83
83
  > page to see examples of integration with deep learning libraries.
84
84
 
85
85
  ## Advanced usage
86
86
 
87
- Go to [advanced usage](https://github.com/sjmikler/progress-table/blob/main/docs//advanced-usage.md) page for more information.
87
+ Go to [advanced usage](https://github.com/szmikler/progress-table/blob/main/docs//advanced-usage.md) page for more information.
88
88
 
89
89
  ## Troubleshooting
90
90
 
@@ -112,7 +112,7 @@ pip install progress-table
112
112
 
113
113
  ## Links
114
114
 
115
- * [See on GitHub](https://github.com/gahaalt/progress-table)
115
+ * [See on GitHub](https://github.com/szmikler/progress-table)
116
116
  * [See on PyPI](https://pypi.org/project/progress-table)
117
117
 
118
118
  ## Alternatives
@@ -10,7 +10,7 @@ Supported features:
10
10
  """
11
11
 
12
12
  __license__ = "MIT"
13
- __version__ = "3.3.2"
13
+ __version__ = "3.3.4"
14
14
  __author__ = "Szymon Mikler"
15
15
 
16
16
  from progress_table.progress_table import ProgressTable, styles
@@ -358,9 +358,13 @@ class ProgressTable:
358
358
  else:
359
359
  self.column_names.append(name)
360
360
 
361
- resolved_width = width or self.column_width or self.DEFAULT_COLUMN_WIDTH
362
- if not width and resolved_width < len(str(name)):
363
- resolved_width = len(str(name))
361
+ if width is not None:
362
+ resolved_width = width
363
+ elif self.column_width is not None:
364
+ resolved_width = self.column_width
365
+ else:
366
+ resolved_width = self.DEFAULT_COLUMN_WIDTH
367
+ resolved_width = max(resolved_width, len(name))
364
368
  self.column_widths[name] = resolved_width
365
369
  self.column_colors[name] = maybe_convert_to_colorama(color or self.column_color or self.DEFAULT_COLUMN_COLOR)
366
370
  self.column_alignments[name] = alignment or self.column_alignment or self.DEFAULT_COLUMN_ALIGNMENT
File without changes
@@ -20,12 +20,13 @@ classifiers = [
20
20
  "Programming Language :: Python :: 3.12",
21
21
  "Programming Language :: Python :: 3.13",
22
22
  "Programming Language :: Python :: 3.14",
23
+ "Typing :: Typed",
23
24
  ]
24
25
  readme = "README_pypi.md"
25
26
 
26
27
  [project.urls]
27
- Home = "https://github.com/gahaalt/progress-table"
28
- Documentation = "https://github.com/sjmikler/progress-table/blob/main/docs"
28
+ Home = "https://github.com/szmikler/progress-table"
29
+ Documentation = "https://github.com/szmikler/progress-table/blob/main/docs"
29
30
 
30
31
  [project.optional-dependencies]
31
32
  dev = ["ruff", "pyright", "pytest", "pytest-cov", "hatch", "twine"]