mapfile_parser 2.12.2__tar.gz → 2.13.1__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.
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/CHANGELOG.md +32 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/Cargo.lock +1 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/Cargo.toml +1 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/PKG-INFO +3 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/README.md +2 -2
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/pyproject.toml +23 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/__init__.py +6 -9
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/__main__.py +1 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/__init__.py +0 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/bss_check.py +3 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/first_diff.py +3 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/jsonify.py +3 -2
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/objdiff_report.py +5 -5
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/pj64_syms.py +3 -2
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/progress.py +4 -4
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/sym_info.py +39 -22
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/symbol_sizes_csv.py +2 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/upload_frogress.py +3 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/internals/objdiff_report.py +2 -3
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/mapfile.py +199 -55
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/mapfile_parser.pyi +10 -5
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/mapfile_rs.py +5 -6
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/utils.py +2 -2
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/found_symbol_info.rs +33 -21
- mapfile_parser-2.13.1/src/rs/iterators/iter_mapfile_syms_by_name.rs +58 -0
- mapfile_parser-2.13.1/src/rs/iterators/iter_mapfile_syms_by_vram.rs +50 -0
- mapfile_parser-2.13.1/src/rs/iterators/iter_mapfile_syms_by_vrom.rs +50 -0
- mapfile_parser-2.13.1/src/rs/iterators/iter_segment_syms_by_name.rs +55 -0
- mapfile_parser-2.13.1/src/rs/iterators/mod.rs +12 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/lib.rs +3 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/mapfile.rs +19 -2
- mapfile_parser-2.13.1/src/rs/maybe_found_symbol_info.rs +66 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/parser.rs +1 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/section.rs +74 -45
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/segment.rs +55 -2
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/symbol.rs +28 -4
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/symbol_decomp_state.rs +1 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/uv.lock +1 -1
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/.gitattributes +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/.gitignore +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/LICENSE +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/internals/__init__.py +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/progress_stats.py +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/progress_stats_rs.py +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/maps_comparison_info.rs +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/progress_stats.rs +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/report.rs +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/symbol_comparison_info.rs +0 -0
- {mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/rs/utils.rs +0 -0
|
@@ -7,6 +7,33 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
|
|
|
7
7
|
|
|
8
8
|
## [Unreleased]
|
|
9
9
|
|
|
10
|
+
## [2.13.1] - 2026-08-18
|
|
11
|
+
|
|
12
|
+
### Fixed
|
|
13
|
+
|
|
14
|
+
- Fix `first_diff` and some lookup functions grabbing the first existing
|
|
15
|
+
`.NON_MATCHING` marker instead of the actual symbol.
|
|
16
|
+
|
|
17
|
+
## [2.13.0] - 2026-06-28
|
|
18
|
+
|
|
19
|
+
### Added
|
|
20
|
+
|
|
21
|
+
- `findPossibleSymbolsByVram`, `findPossibleSymbolsByVrom`, and
|
|
22
|
+
`findPossibleSymbolsByName` for `MapFile` and `findPossibleSymbolByVram`,
|
|
23
|
+
`findPossibleSymbolByVrom`, and `findPossibleSymbolsByName` for `Segment`.
|
|
24
|
+
- Allow iterating over the mapfile looking for multiple symbols that could
|
|
25
|
+
match either the vram, vrom or name given instead of stopping at the first
|
|
26
|
+
one that matches the criteria.
|
|
27
|
+
- `Symbol::isNonmatching`: If true, the current symbol is a `.NON_MATCHING`
|
|
28
|
+
marker symbol.
|
|
29
|
+
- `Section::containsVram`, `Section::containsVrom`, `Segment::containsVram`,
|
|
30
|
+
`Segment::containsVrom`.
|
|
31
|
+
|
|
32
|
+
### Changed
|
|
33
|
+
|
|
34
|
+
- `sym_info` now iterates over every possible vram/vrom address for every
|
|
35
|
+
segment instead of only printing the first found one.
|
|
36
|
+
|
|
10
37
|
## [2.12.2] - 2026-05-30
|
|
11
38
|
|
|
12
39
|
### Fixed
|
|
@@ -708,10 +735,12 @@ Full changes: <https://github.com/Decompollaborate/mapfile_parser/compare/702a73
|
|
|
708
735
|
|
|
709
736
|
- Initial release
|
|
710
737
|
|
|
711
|
-
[unreleased]: https://github.com/Decompollaborate/mapfile_parser/compare/2.
|
|
738
|
+
[unreleased]: https://github.com/Decompollaborate/mapfile_parser/compare/2.13.0...HEAD
|
|
712
739
|
|
|
713
|
-
[2.
|
|
714
|
-
[2.
|
|
740
|
+
[2.13.1]: https://github.com/Decompollaborate/mapfile_parser/compare/2.13.0...2.13.1
|
|
741
|
+
[2.13.0]: https://github.com/Decompollaborate/mapfile_parser/compare/2.12.2...2.13.0
|
|
742
|
+
[2.12.2]: https://github.com/Decompollaborate/mapfile_parser/compare/2.12.1...2.12.2
|
|
743
|
+
[2.12.1]: https://github.com/Decompollaborate/mapfile_parser/compare/2.12.0...2.12.1
|
|
715
744
|
[2.12.0]: https://github.com/Decompollaborate/mapfile_parser/compare/2.11.0...2.12.0
|
|
716
745
|
[2.11.0]: https://github.com/Decompollaborate/mapfile_parser/compare/2.10.0...2.11.0
|
|
717
746
|
[2.10.0]: https://github.com/Decompollaborate/mapfile_parser/compare/2.9.4...2.10.0
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: mapfile_parser
|
|
3
|
-
Version: 2.
|
|
3
|
+
Version: 2.13.1
|
|
4
4
|
Classifier: Programming Language :: Rust
|
|
5
5
|
Classifier: Programming Language :: Python :: Implementation :: CPython
|
|
6
6
|
Classifier: Programming Language :: Python :: Implementation :: PyPy
|
|
@@ -51,7 +51,7 @@ If you use a `requirements.txt` file in your repository, then you can add
|
|
|
51
51
|
this library with the following line:
|
|
52
52
|
|
|
53
53
|
```txt
|
|
54
|
-
mapfile_parser>=2.
|
|
54
|
+
mapfile_parser>=2.13,<3.0.0
|
|
55
55
|
```
|
|
56
56
|
|
|
57
57
|
#### Development version
|
|
@@ -90,7 +90,7 @@ cargo add mapfile_parser
|
|
|
90
90
|
Or add the following line manually to your `Cargo.toml` file:
|
|
91
91
|
|
|
92
92
|
```toml
|
|
93
|
-
mapfile_parser = "2.
|
|
93
|
+
mapfile_parser = "2.13"
|
|
94
94
|
```
|
|
95
95
|
|
|
96
96
|
## Versioning and changelog
|
|
@@ -36,7 +36,7 @@ If you use a `requirements.txt` file in your repository, then you can add
|
|
|
36
36
|
this library with the following line:
|
|
37
37
|
|
|
38
38
|
```txt
|
|
39
|
-
mapfile_parser>=2.
|
|
39
|
+
mapfile_parser>=2.13,<3.0.0
|
|
40
40
|
```
|
|
41
41
|
|
|
42
42
|
#### Development version
|
|
@@ -75,7 +75,7 @@ cargo add mapfile_parser
|
|
|
75
75
|
Or add the following line manually to your `Cargo.toml` file:
|
|
76
76
|
|
|
77
77
|
```toml
|
|
78
|
-
mapfile_parser = "2.
|
|
78
|
+
mapfile_parser = "2.13"
|
|
79
79
|
```
|
|
80
80
|
|
|
81
81
|
## Versioning and changelog
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
|
|
4
4
|
[project]
|
|
5
5
|
name = "mapfile_parser"
|
|
6
|
-
version = "2.
|
|
6
|
+
version = "2.13.1"
|
|
7
7
|
description = "Map file parser library focusing decompilation projects"
|
|
8
8
|
readme = "README.md"
|
|
9
9
|
requires-python = ">=3.8"
|
|
@@ -33,3 +33,25 @@ mapfile_parser = "mapfile_parser.__main__:mapfileParserMain"
|
|
|
33
33
|
features = ["pyo3/extension-module", "python_bindings"]
|
|
34
34
|
# https://github.com/PyO3/maturin/blob/0dee40510083c03607834c821eea76964140a126/Readme.md#mixed-rustpython-projects
|
|
35
35
|
python-source = "src"
|
|
36
|
+
|
|
37
|
+
[tool.ruff.lint]
|
|
38
|
+
# Keep alphabetically sorted
|
|
39
|
+
# TODO: fix
|
|
40
|
+
ignore = [
|
|
41
|
+
"B006",
|
|
42
|
+
"B008",
|
|
43
|
+
"BLE001",
|
|
44
|
+
"C408",
|
|
45
|
+
"EXE001",
|
|
46
|
+
"EXE005",
|
|
47
|
+
"FLY002",
|
|
48
|
+
"PERF402",
|
|
49
|
+
"PLC0414",
|
|
50
|
+
"PLR1722",
|
|
51
|
+
"PLW0127",
|
|
52
|
+
"PLW0128",
|
|
53
|
+
"PYI015",
|
|
54
|
+
"RUF012",
|
|
55
|
+
"SIM102",
|
|
56
|
+
"UP028",
|
|
57
|
+
]
|
|
@@ -5,25 +5,22 @@
|
|
|
5
5
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
|
-
__version_info__ = (2,
|
|
8
|
+
__version_info__ = (2, 13, 1)
|
|
9
9
|
__version__ = ".".join(map(str, __version_info__)) # + "-dev0"
|
|
10
10
|
__author__ = "Decompollaborate"
|
|
11
11
|
|
|
12
|
+
from . import frontends as frontends
|
|
12
13
|
from . import utils as utils
|
|
13
|
-
|
|
14
|
+
from .mapfile import FoundSymbolInfo as FoundSymbolInfo
|
|
14
15
|
from .mapfile import MapFile as MapFile
|
|
15
|
-
from .mapfile import
|
|
16
|
+
from .mapfile import MapsComparisonInfo as MapsComparisonInfo
|
|
17
|
+
from .mapfile import ReportCategories as ReportCategories
|
|
16
18
|
from .mapfile import Section as Section
|
|
17
19
|
from .mapfile import Segment as Segment
|
|
18
|
-
from .mapfile import
|
|
20
|
+
from .mapfile import Symbol as Symbol
|
|
19
21
|
from .mapfile import SymbolComparisonInfo as SymbolComparisonInfo
|
|
20
|
-
from .mapfile import MapsComparisonInfo as MapsComparisonInfo
|
|
21
|
-
from .mapfile import ReportCategories as ReportCategories
|
|
22
|
-
|
|
23
22
|
from .progress_stats import ProgressStats as ProgressStats
|
|
24
23
|
|
|
25
|
-
from . import frontends as frontends
|
|
26
|
-
|
|
27
24
|
# Renamed types.
|
|
28
25
|
# TODO: remove on version 3.0
|
|
29
26
|
File = Section
|
|
@@ -7,11 +7,11 @@ from __future__ import annotations
|
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
9
|
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
10
|
from pathlib import Path
|
|
12
11
|
|
|
13
|
-
|
|
14
|
-
|
|
12
|
+
import decomp_settings
|
|
13
|
+
|
|
14
|
+
from .. import mapfile, utils
|
|
15
15
|
|
|
16
16
|
|
|
17
17
|
def getComparison(
|
|
@@ -7,12 +7,12 @@ from __future__ import annotations
|
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
9
|
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
10
|
from pathlib import Path
|
|
12
11
|
from typing import Literal
|
|
13
12
|
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
import decomp_settings
|
|
14
|
+
|
|
15
|
+
from .. import mapfile, utils
|
|
16
16
|
|
|
17
17
|
|
|
18
18
|
def doFirstDiff(
|
|
@@ -6,11 +6,12 @@
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
|
-
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
9
|
import json
|
|
10
|
+
from collections.abc import Callable
|
|
12
11
|
from pathlib import Path
|
|
13
12
|
|
|
13
|
+
import decomp_settings
|
|
14
|
+
|
|
14
15
|
from .. import mapfile
|
|
15
16
|
|
|
16
17
|
|
{mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/objdiff_report.py
RENAMED
|
@@ -6,14 +6,14 @@
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
|
-
from collections.abc import Callable
|
|
10
9
|
import dataclasses
|
|
11
|
-
import decomp_settings
|
|
12
|
-
from pathlib import Path
|
|
13
10
|
import os
|
|
11
|
+
from collections.abc import Callable
|
|
12
|
+
from pathlib import Path
|
|
13
|
+
|
|
14
|
+
import decomp_settings
|
|
14
15
|
|
|
15
|
-
from .. import mapfile
|
|
16
|
-
from .. import utils
|
|
16
|
+
from .. import mapfile, utils
|
|
17
17
|
from ..internals import objdiff_report as report_internal
|
|
18
18
|
|
|
19
19
|
|
|
@@ -6,11 +6,12 @@
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
|
+
import sys
|
|
9
10
|
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
11
|
from pathlib import Path
|
|
12
12
|
from typing import TextIO
|
|
13
|
-
|
|
13
|
+
|
|
14
|
+
import decomp_settings
|
|
14
15
|
|
|
15
16
|
from .. import mapfile
|
|
16
17
|
|
|
@@ -6,13 +6,13 @@
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
|
-
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
9
|
import json
|
|
10
|
+
from collections.abc import Callable
|
|
12
11
|
from pathlib import Path
|
|
13
12
|
|
|
14
|
-
|
|
15
|
-
|
|
13
|
+
import decomp_settings
|
|
14
|
+
|
|
15
|
+
from .. import mapfile, progress_stats
|
|
16
16
|
|
|
17
17
|
|
|
18
18
|
def getProgress(
|
|
@@ -7,11 +7,12 @@ from __future__ import annotations
|
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
9
|
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
10
|
from pathlib import Path
|
|
11
|
+
from typing import Generator
|
|
12
|
+
|
|
13
|
+
import decomp_settings
|
|
12
14
|
|
|
13
|
-
from .. import mapfile
|
|
14
|
-
from .. import utils
|
|
15
|
+
from .. import mapfile, utils
|
|
15
16
|
|
|
16
17
|
|
|
17
18
|
def doSymInfo(
|
|
@@ -31,36 +32,52 @@ def doSymInfo(
|
|
|
31
32
|
if plfResolver is not None:
|
|
32
33
|
mapFile = mapFile.resolvePartiallyLinkedFiles(plfResolver)
|
|
33
34
|
|
|
34
|
-
|
|
35
|
+
count = 0
|
|
36
|
+
for info in iterateSymbols(
|
|
37
|
+
mapFile,
|
|
38
|
+
symName,
|
|
39
|
+
as_vram,
|
|
40
|
+
as_vrom,
|
|
41
|
+
as_name,
|
|
42
|
+
):
|
|
43
|
+
print(info.getAsStrPlusOffset(symName))
|
|
44
|
+
count += 1
|
|
45
|
+
|
|
46
|
+
if count == 0:
|
|
47
|
+
print(f"'{symName}' not found in map file '{mapPath}'")
|
|
48
|
+
return 1
|
|
49
|
+
return 0
|
|
50
|
+
|
|
35
51
|
|
|
52
|
+
def iterateSymbols(
|
|
53
|
+
mapFile: mapfile.MapFile,
|
|
54
|
+
symName: str,
|
|
55
|
+
as_vram: bool,
|
|
56
|
+
as_vrom: bool,
|
|
57
|
+
as_name: bool,
|
|
58
|
+
) -> Generator[mapfile.MaybeFoundSymbolInfo]:
|
|
36
59
|
if as_vram:
|
|
37
60
|
address = int(symName, 0)
|
|
38
|
-
info
|
|
61
|
+
for info in mapFile.findPossibleSymbolsByVram(address):
|
|
62
|
+
yield info
|
|
39
63
|
elif as_vrom:
|
|
40
64
|
address = int(symName, 0)
|
|
41
|
-
info
|
|
65
|
+
for info in mapFile.findPossibleSymbolsByVrom(address):
|
|
66
|
+
yield info
|
|
42
67
|
elif as_name:
|
|
43
|
-
info
|
|
68
|
+
for info in mapFile.findPossibleSymbolsByName(symName):
|
|
69
|
+
yield info
|
|
44
70
|
|
|
45
71
|
# Start the guessing game
|
|
46
72
|
elif utils.convertibleToInt(symName, 0):
|
|
47
73
|
address = int(symName, 0)
|
|
48
|
-
info
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
74
|
+
for info in mapFile.findPossibleSymbolsByVram(address):
|
|
75
|
+
yield info
|
|
76
|
+
for info in mapFile.findPossibleSymbolsByVrom(address):
|
|
77
|
+
yield info
|
|
52
78
|
else:
|
|
53
|
-
info
|
|
54
|
-
|
|
55
|
-
if info is not None:
|
|
56
|
-
print(info.getAsStrPlusOffset(symName))
|
|
57
|
-
return 0
|
|
58
|
-
print(f"'{symName}' not found in map file '{mapPath}'")
|
|
59
|
-
if len(possibleFiles) > 0:
|
|
60
|
-
print("But it may be a local symbol of either of the following files:")
|
|
61
|
-
for f in possibleFiles:
|
|
62
|
-
print(f" {f.asStr()})")
|
|
63
|
-
return 1
|
|
79
|
+
for info in mapFile.findPossibleSymbolsByName(symName):
|
|
80
|
+
yield info
|
|
64
81
|
|
|
65
82
|
|
|
66
83
|
def processArguments(
|
{mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/frontends/upload_frogress.py
RENAMED
|
@@ -7,12 +7,12 @@ from __future__ import annotations
|
|
|
7
7
|
|
|
8
8
|
import argparse
|
|
9
9
|
from collections.abc import Callable
|
|
10
|
-
import decomp_settings
|
|
11
10
|
from pathlib import Path
|
|
11
|
+
|
|
12
|
+
import decomp_settings
|
|
12
13
|
import requests # type: ignore
|
|
13
14
|
|
|
14
|
-
from .. import utils
|
|
15
|
-
from .. import progress_stats
|
|
15
|
+
from .. import progress_stats, utils
|
|
16
16
|
from . import progress
|
|
17
17
|
|
|
18
18
|
|
{mapfile_parser-2.12.2 → mapfile_parser-2.13.1}/src/mapfile_parser/internals/objdiff_report.py
RENAMED
|
@@ -6,8 +6,8 @@
|
|
|
6
6
|
from __future__ import annotations
|
|
7
7
|
|
|
8
8
|
import dataclasses
|
|
9
|
-
from pathlib import Path
|
|
10
9
|
import json
|
|
10
|
+
from pathlib import Path
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
@dataclasses.dataclass
|
|
@@ -42,8 +42,7 @@ class Report:
|
|
|
42
42
|
# Calculate the size for the first column
|
|
43
43
|
columnSize = 8
|
|
44
44
|
for name, _ in new_cats:
|
|
45
|
-
|
|
46
|
-
columnSize = len(name)
|
|
45
|
+
columnSize = max(columnSize, len(name))
|
|
47
46
|
columnSize += 1
|
|
48
47
|
|
|
49
48
|
categoryStr = "{0:<{1}}".format("Category", columnSize)
|