Fri, 02 Aug 2024 18:02:56 +0200
Third Party Packages
- Upgraded `pip-licenses` to version 5.0.0.
--- a/docs/ThirdParty.md Fri Aug 02 14:35:21 2024 +0200 +++ b/docs/ThirdParty.md Fri Aug 02 18:02:56 2024 +0200 @@ -7,7 +7,7 @@ |:------------:|:---------:|:----------------------------| | eradicate | 2.3.0 | MIT License (Expat License) | | mccabe | 0.7.0 | MIT License (Expat License) | -| pip-licenses | 4.4.0 | MIT License (MIT) | +| pip-licenses | 5.0.0 | MIT License (MIT) | | pycodestyle | 2.11.1 | MIT License (Expat License) | | pyflakes | 3.2.0 | MIT License (MIT) | | | | |
--- a/docs/changelog.md Fri Aug 02 14:35:21 2024 +0200 +++ b/docs/changelog.md Fri Aug 02 18:02:56 2024 +0200 @@ -2,6 +2,8 @@ ### Version 24.9 - bug fixes +- Third Party Packages + - Upgraded `pip-licenses` to version 5.0.0. ### Version 24.8 - bug fixes
--- a/src/eric7/PipInterface/piplicenses.py Fri Aug 02 14:35:21 2024 +0200 +++ b/src/eric7/PipInterface/piplicenses.py Fri Aug 02 18:02:56 2024 +0200 @@ -38,6 +38,8 @@ # - changed 'create_licenses_table' to 'create_licenses_list' # - changed 'create_summary_table' to 'create_summary_list' # - changed 'create_output_string' to return a JSON string +# - removed 'load_config_from_file()' because we only use command line +# configuration # from __future__ import annotations @@ -66,13 +68,10 @@ __pkgname__ = "pip-licenses" -__version__ = "4.4.0" -__author__ = "raimon" -__license__ = "MIT" +__version__ = "5.0.0" __summary__ = ( "Dump the software license list of Python packages installed with pip." ) -__url__ = "https://github.com/raimon49/pip-licenses" FIELD_NAMES = ( @@ -678,6 +677,12 @@ ] +def get_value_from_enum( + enum_cls: Type[NoValueEnum], value: str +) -> NoValueEnum: + return getattr(enum_cls, value_to_enum_key(value)) + + MAP_DEST_TO_ENUM = { 'from_': FromArg, 'order': OrderArg, @@ -693,11 +698,10 @@ option_string: Optional[str] = None, ) -> None: enum_cls = MAP_DEST_TO_ENUM[self.dest] - values = value_to_enum_key(values) - setattr(namespace, self.dest, getattr(enum_cls, values)) + setattr(namespace, self.dest, get_value_from_enum(enum_cls, values)) -def create_parser(): +def create_parser() -> CompatibleArgumentParser: parser = CompatibleArgumentParser( description=__summary__, formatter_class=CustomHelpFormatter )