From 9940fbac5927fb514f88835fafad6eb084a5e2a4 Mon Sep 17 00:00:00 2001 From: Rene Leonhardt <65483435+reneleonhardt@users.noreply.github.com> Date: Sun, 11 Jun 2023 16:59:32 +0200 Subject: [PATCH 1/2] Update tzlocal and red-black-tree-mod Fix for #366 --- CHANGELOG.md | 4 ++++ extract_msg/__init__.py | 4 ++-- extract_msg/utils.py | 2 +- requirements.txt | 4 ++-- 4 files changed, 9 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 00bb4278..757d4932 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,7 @@ +**v0.41.4** +* Fixed [[TeamMsgExtractor #366](https://github.com/TeamMsgExtractor/msg-extractor/pull/366)] +* Updated `tzlocal` and `red-black-tree-mod` to allow other projects to update their dependency trees. + **v0.41.3** * [[TeamMsgExtractor #365](https://github.com/TeamMsgExtractor/msg-extractor/issues/365)] Fixed an issue that would cause certain values retrieved from the header to not be decoded properly. It does this when retrieving the values, so nothing about the header has been changed. * Added new property `MessageBase.headerText` which is the text content of the header stream. Adjusted other things to use this instead of trying to retrieve the stream directly in multiple places. diff --git a/extract_msg/__init__.py b/extract_msg/__init__.py index 0021ce89..3910d1a2 100644 --- a/extract_msg/__init__.py +++ b/extract_msg/__init__.py @@ -27,8 +27,8 @@ # along with this program. If not, see . __author__ = 'Destiny Peterson & Matthew Walker' -__date__ = '2023-06-10' -__version__ = '0.41.3' +__date__ = '2023-06-11' +__version__ = '0.41.4' __all__ = [ # Modules: diff --git a/extract_msg/utils.py b/extract_msg/utils.py index d9801e3a..76b8c380 100644 --- a/extract_msg/utils.py +++ b/extract_msg/utils.py @@ -180,7 +180,7 @@ def decodeRfc2047(encoded : str) -> str: # decode_header header will return a string instead of bytes for the first # object if the input is not encoded, something that is frustrating. return ''.join( - x[0].decode(x[1] or 'ascii') if isinstance(x[0], bytes) else x + x[0].decode(x[1] or 'ascii') if isinstance(x[0], bytes) else x[0] for x in email.header.decode_header(encoded) ) diff --git a/requirements.txt b/requirements.txt index 72792d2a..2ce9fff0 100644 --- a/requirements.txt +++ b/requirements.txt @@ -2,10 +2,10 @@ # First level requirements imapclient>=2.3.0,<3 olefile==0.46 -tzlocal==4.2 +tzlocal>=4.2,<6 compressed_rtf==1.0.6 ebcdic==1.1.1 beautifulsoup4>=4.11.1,<4.13 RTFDE==0.0.2 chardet>=4.0.0,<6 -red-black-tree-mod==1.20 +red-black-tree-mod>=1.20,<2 From 5f7dd4738859625b4af03fda8d77fef35c1e17c8 Mon Sep 17 00:00:00 2001 From: Rene Leonhardt <65483435+reneleonhardt@users.noreply.github.com> Date: Sun, 11 Jun 2023 17:57:57 +0200 Subject: [PATCH 2/2] Updated requirements and changelog --- CHANGELOG.md | 2 +- requirements.txt | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 757d4932..1f8992af 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,6 +1,6 @@ **v0.41.4** * Fixed [[TeamMsgExtractor #366](https://github.com/TeamMsgExtractor/msg-extractor/pull/366)] -* Updated `tzlocal` and `red-black-tree-mod` to allow other projects to update their dependency trees. +* Updated `tzlocal` and allow future updates for `compressed_rtf` and `ebcdic`. **v0.41.3** * [[TeamMsgExtractor #365](https://github.com/TeamMsgExtractor/msg-extractor/issues/365)] Fixed an issue that would cause certain values retrieved from the header to not be decoded properly. It does this when retrieving the values, so nothing about the header has been changed. diff --git a/requirements.txt b/requirements.txt index 2ce9fff0..3125d5d8 100644 --- a/requirements.txt +++ b/requirements.txt @@ -3,9 +3,9 @@ imapclient>=2.3.0,<3 olefile==0.46 tzlocal>=4.2,<6 -compressed_rtf==1.0.6 -ebcdic==1.1.1 +compressed_rtf>=1.0.6,<2 +ebcdic>=1.1.1,<2 beautifulsoup4>=4.11.1,<4.13 RTFDE==0.0.2 chardet>=4.0.0,<6 -red-black-tree-mod>=1.20,<2 +red-black-tree-mod==1.20