diff --git a/Pipfile.lock b/Pipfile.lock index c0afbeea7..d1627e63e 100644 --- a/Pipfile.lock +++ b/Pipfile.lock @@ -24,11 +24,11 @@ }, "anyio": { "hashes": [ - "sha256:cfdb2b588b9fc25ede96d8db56ed50848b0b649dca3dd1df0b11f683bb9e0b5f", - "sha256:f7ed51751b2c2add651e5747c891b47e26d2a21be5d32d9311dfe9692f3e5d7a" + "sha256:56a415fbc462291813a94528a779597226619c8e78af7de0507333f700011e5f", + "sha256:5a0bec7085176715be77df87fc66d6c9d70626bd752fcc85f57cdbee5b3760da" ], "markers": "python_version >= '3.8'", - "version": "==4.0.0" + "version": "==4.1.0" }, "asgiref": { "hashes": [ @@ -164,11 +164,11 @@ }, "certifi": { "hashes": [ - "sha256:539cc1d13202e33ca466e88b2807e29f4c13049d6d87031a3c110744495cb082", - "sha256:92d6037539857d8206b8f6ae472e8b77db8058fec5937a1ef3f54304089edbb9" + "sha256:9b469f3a900bf28dc19b8cfbf8019bf47f7fdd1a65a1d4ffb98fc14166beb4d1", + "sha256:e036ab49d5b79556f99cfc2d9320b34cfbe5be05c5871b51de9329f0603b0474" ], "markers": "python_version >= '3.6'", - "version": "==2023.7.22" + "version": "==2023.11.17" }, "cffi": { "hashes": [ @@ -540,11 +540,11 @@ }, "exceptiongroup": { "hashes": [ - "sha256:097acd85d473d75af5bb98e41b61ff7fe35efe6675e4f9370ec6ec5126d160e9", - "sha256:343280667a4585d195ca1cf9cef84a4e178c4b6cf2274caef9859782b567d5e3" + "sha256:4bfd3996ac73b41e9b9628b04e079f193850720ea5945fc96a08633c66912f14", + "sha256:91f5c769735f051a4290d52edd0858999b57e5876e9f85937691bd4c9fa3ed68" ], "markers": "python_version < '3.11'", - "version": "==1.1.3" + "version": "==1.2.0" }, "filelock": { "hashes": [ @@ -566,12 +566,12 @@ }, "gotenberg-client": { "hashes": [ - "sha256:4508ecb913ef2d553dd2ceb78e32cee001000ba08c910ba1f9ace38350d1589e", - "sha256:7a3f8a02caee768391373b3610c6ec25a853cccf391ed6b5d5a1292c3ed15e7e" + "sha256:3026726d1a47f41e9d43f18c95e530ff64f506e2ec436f116a088da27c7430da", + "sha256:c2555f7401faa48213a7cbe29c5e4a68316a003a6953753bc58d1e2b19873771" ], "index": "pypi", "markers": "python_version >= '3.8'", - "version": "==0.3.0" + "version": "==0.4.0" }, "gunicorn": { "hashes": [ @@ -753,11 +753,11 @@ "http2" ], "hashes": [ - "sha256:fec7d6cc5c27c578a391f7e87b9aa7d3d8fbcd034f6399f9f79b45bcc12a866a", - "sha256:ffd96d5cf901e63863d9f1b4b6807861dbea4d301613415d9e6e57ead15fc5d0" + "sha256:8b8fcaa0c8ea7b05edd69a094e63a2094c4efcb48129fb757361bc423c0ad9e8", + "sha256:a05d3d052d9b2dfce0e3896636467f8a5342fb2b902c819428e1ac65413ca118" ], "markers": "python_version >= '3.9'", - "version": "==0.25.1" + "version": "==0.25.2" }, "humanize": { "hashes": [ @@ -777,11 +777,11 @@ }, "idna": { "hashes": [ - "sha256:814f528e8dead7d329833b91c5faa87d60bf71824cd12a7530b5526063d02cb4", - "sha256:90b77e79eaa3eba6de819a0c442c0b4ceefc341a7a2ab77d7562bf49f425c5c2" + "sha256:9ecdbbd083b06798ae1e86adcbfe8ab1479cf864e4ee30fe4e46a003d12491ca", + "sha256:c05567e9c24a6b9faaa835c4821bad0590fbb9d5779e7caa6e1cc4978e7eb24f" ], "markers": "python_version >= '3.5'", - "version": "==3.4" + "version": "==3.6" }, "imap-tools": { "hashes": [ @@ -1849,7 +1849,7 @@ "sha256:8f92fc8806f9a6b641eaa5318da32b44d401efaac0f6678c9bc448ba3605faa0", "sha256:df8e4339e9cb77357558cbdbceca33c303714cf861d1eef15e1070055ae8b7ef" ], - "markers": "python_version < '3.11'", + "markers": "python_version < '3.10'", "version": "==4.8.0" }, "tzdata": { diff --git a/docker/compose/docker-compose.ci-test.yml b/docker/compose/docker-compose.ci-test.yml index e9ff1d29e..7987b8798 100644 --- a/docker/compose/docker-compose.ci-test.yml +++ b/docker/compose/docker-compose.ci-test.yml @@ -6,7 +6,7 @@ version: "3.7" services: gotenberg: - image: docker.io/gotenberg/gotenberg:7.8 + image: docker.io/gotenberg/gotenberg:7.10 hostname: gotenberg container_name: gotenberg network_mode: host @@ -17,6 +17,8 @@ services: - "gotenberg" - "--chromium-disable-javascript=true" - "--chromium-allow-list=file:///tmp/.*" + - "--log-level=warn" + - "--log-format=text" tika: image: ghcr.io/paperless-ngx/tika:latest hostname: tika diff --git a/docker/compose/docker-compose.mariadb-tika.yml b/docker/compose/docker-compose.mariadb-tika.yml index 7513655d0..10d0e61a2 100644 --- a/docker/compose/docker-compose.mariadb-tika.yml +++ b/docker/compose/docker-compose.mariadb-tika.yml @@ -83,7 +83,7 @@ services: PAPERLESS_TIKA_ENDPOINT: http://tika:9998 gotenberg: - image: docker.io/gotenberg/gotenberg:7.8 + image: docker.io/gotenberg/gotenberg:7.10 restart: unless-stopped # The gotenberg chromium route is used to convert .eml files. We do not # want to allow external content like tracking pixels or even javascript. diff --git a/docker/compose/docker-compose.postgres-tika.yml b/docker/compose/docker-compose.postgres-tika.yml index d040b307c..5ec2595c1 100644 --- a/docker/compose/docker-compose.postgres-tika.yml +++ b/docker/compose/docker-compose.postgres-tika.yml @@ -77,7 +77,7 @@ services: PAPERLESS_TIKA_ENDPOINT: http://tika:9998 gotenberg: - image: docker.io/gotenberg/gotenberg:7.8 + image: docker.io/gotenberg/gotenberg:7.10 restart: unless-stopped # The gotenberg chromium route is used to convert .eml files. We do not diff --git a/docker/compose/docker-compose.sqlite-tika.yml b/docker/compose/docker-compose.sqlite-tika.yml index 37f619c17..ed3842224 100644 --- a/docker/compose/docker-compose.sqlite-tika.yml +++ b/docker/compose/docker-compose.sqlite-tika.yml @@ -65,7 +65,7 @@ services: PAPERLESS_TIKA_ENDPOINT: http://tika:9998 gotenberg: - image: docker.io/gotenberg/gotenberg:7.8 + image: docker.io/gotenberg/gotenberg:7.10 restart: unless-stopped # The gotenberg chromium route is used to convert .eml files. We do not diff --git a/src/paperless_mail/parsers.py b/src/paperless_mail/parsers.py index 4b3e5686e..9bc7081d6 100644 --- a/src/paperless_mail/parsers.py +++ b/src/paperless_mail/parsers.py @@ -215,6 +215,8 @@ class MailDocumentParser(DocumentParser): mail_message.attachments, ) + self.log.debug("Merging email text and HTML content into single PDF") + with GotenbergClient( host=settings.TIKA_GOTENBERG_ENDPOINT, timeout=settings.CELERY_TASK_TIME_LIMIT, @@ -348,7 +350,7 @@ class MailDocumentParser(DocumentParser): text = compiled_close.sub("