textproc/py-tika-client: New port

Python REST client for Apache Tika server
This commit is contained in:
Michael Gmelin 2024-02-12 14:51:31 +01:00
parent 2dde972e0c
commit f836820133
4 changed files with 47 additions and 0 deletions

View File

@ -1616,6 +1616,7 @@
SUBDIR += py-textual
SUBDIR += py-textwrap3
SUBDIR += py-three-merge
SUBDIR += py-tika-client
SUBDIR += py-tiktoken
SUBDIR += py-tinycss
SUBDIR += py-tinycss2

View File

@ -0,0 +1,30 @@
PORTNAME= tika-client
PORTVERSION= 0.5.0
CATEGORIES= textproc python
MASTER_SITES= PYPI
PKGNAMEPREFIX= ${PYTHON_PKGNAMEPREFIX}
DISTNAME= ${PORTNAME:S/-/_/}-${PORTVERSION}
MAINTAINER= grembo@FreeBSD.org
COMMENT= Python REST client for Apache Tika server
WWW= https://github.com/stumpylog/tika-client
LICENSE= MPL20
LICENSE_FILE= ${WRKSRC}/LICENSE.txt
BUILD_DEPENDS= ${PYTHON_PKGNAMEPREFIX}hatchling>=0:devel/py-hatchling@${PY_FLAVOR}
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}httpx>=0.26:www/py-httpx@${PY_FLAVOR}
TEST_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pytest>=0:devel/py-pytest@${PY_FLAVOR} \
${PYTHON_PKGNAMEPREFIX}pytest-httpx>=0:devel/py-pytest-httpx@${PY_FLAVOR}
USES= python
USE_PYTHON= autoplist pep517
TEST_ENV= PYTHONPATH=${WRKSRC}/src
NO_ARCH= yes
do-test:
cd ${WRKSRC} && ${SETENV} ${TEST_ENV} ${PYTHON_CMD} -m pytest -v -rs -o addopts=
.include <bsd.port.mk>

View File

@ -0,0 +1,3 @@
TIMESTAMP = 1707592397
SHA256 (tika_client-0.5.0.tar.gz) = f719fbf20f9ef47d12132b38c5848024b260e79c5f0b9ae5ff95c0b2fe3ba350
SIZE (tika_client-0.5.0.tar.gz) = 2170597

View File

@ -0,0 +1,13 @@
Tika Rest Client, simplified: No need to worry about XML or JSON responses,
downloading a Tika jar file or Python 2. Support for Tika 2+ only.
Full support for type hinting
Nearly full test coverage run against an actual Tika server for multiple
Python and PyPy versions
Uses HTTP multipart/form-data to stream files to the server (instead of
reading into memory)
Optional compression for parsing from a file content already in a buffer (as
opposed to a file)