chunkr-ai 0.3.6__py3-none-any.whl → 0.3.7__py3-none-any.whl

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.
chunkr_ai/__init__.py CHANGED
@@ -1,17 +1,12 @@
1
1
  from .api.chunkr import Chunkr
2
- try:
3
- import tomllib
4
- except ImportError:
5
- import tomli as tomllib
6
- from pathlib import Path
2
+ from importlib import metadata
7
3
 
8
- # Read version from pyproject.toml
4
+ # Get version from installed package metadata
9
5
  try:
10
- pyproject_path = Path(__file__).parent.parent.parent / "pyproject.toml"
11
- with open(pyproject_path, "rb") as f:
12
- pyproject_data = tomllib.load(f)
13
- __version__ = pyproject_data["project"]["version"]
14
- except Exception:
6
+ __version__ = metadata.version("chunkr-ai")
7
+ except metadata.PackageNotFoundError:
8
+ # package is not installed
9
+ print("Error: chunkr-ai package not found. contact team@chunkr.ai")
15
10
  __version__ = "unknown"
16
11
 
17
12
  __all__ = ["Chunkr", "__version__"]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: chunkr-ai
3
- Version: 0.3.6
3
+ Version: 0.3.7
4
4
  Summary: Python client for Chunkr: open source document intelligence
5
5
  Author-email: Ishaan Kapoor <ishaan@lumina.sh>
6
6
  License: MIT License
@@ -33,13 +33,13 @@ Requires-Dist: nest-asyncio>=1.6.0
33
33
  Requires-Dist: pillow>=10.0.0
34
34
  Requires-Dist: pydantic>=2.0.0
35
35
  Requires-Dist: python-dotenv>=0.19.0
36
- Requires-Dist: tomli>=1.2.0; python_version < "3.11"
37
36
  Provides-Extra: test
38
37
  Requires-Dist: pytest>=7.0.0; extra == "test"
39
38
  Requires-Dist: pytest-xdist>=3.0.0; extra == "test"
40
39
  Requires-Dist: pytest-asyncio>=0.21.0; extra == "test"
41
40
  Requires-Dist: ruff>=0.9.3; extra == "test"
42
41
  Requires-Dist: matplotlib>=3.10.3; extra == "test"
42
+ Requires-Dist: tomli>=1.2.0; python_version < "3.11" and extra == "test"
43
43
  Dynamic: license-file
44
44
 
45
45
  # Chunkr Python Client
@@ -1,4 +1,4 @@
1
- chunkr_ai/__init__.py,sha256=d4EqExa_cJMpkPuJIaH-KhftCXEhXfNPijbAvqNpYEk,466
1
+ chunkr_ai/__init__.py,sha256=laqbUuQ4E71bW6fMptP8UEbktcFJhLxeOdikoVlievc,368
2
2
  chunkr_ai/models.py,sha256=NvFJOpsgzEyYHhE-flp7Yr9tpTDvFmF4T87jttFRquU,1202
3
3
  chunkr_ai/api/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
4
4
  chunkr_ai/api/auth.py,sha256=5mF9KA_O4b5geRGA0q7ReiZHThyCGKMntu2vewghGXA,775
@@ -9,8 +9,8 @@ chunkr_ai/api/decorators.py,sha256=B-neL5d4N-skq2rjnOfaCVSTz6HEye6udcykacbv7G4,4
9
9
  chunkr_ai/api/misc.py,sha256=pNjbiD5reMdDSkjNTWHn0VgTVsGYn0fl751WuRtSkL8,5389
10
10
  chunkr_ai/api/protocol.py,sha256=LjPrYSq52m1afIlAo0yVGXlGZxPRh8J6g7S4PAit3Zo,388
11
11
  chunkr_ai/api/task_response.py,sha256=omnKkACjN3ijnbG6UncHLI_IDbsaJ1wHu1g4X9JbijU,8017
12
- chunkr_ai-0.3.6.dist-info/licenses/LICENSE,sha256=w3R12yNDyZpMiy2lxy_hvNbsldC75ww79sF0u11rkho,1069
13
- chunkr_ai-0.3.6.dist-info/METADATA,sha256=KQRhytdeklFy2JTlY9G5SLD0rJF2YwdT7on_XZb0as4,7180
14
- chunkr_ai-0.3.6.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
15
- chunkr_ai-0.3.6.dist-info/top_level.txt,sha256=0IZY7PZIiS8bw5r4NUQRUQ-ATi-L_3vLQVq3ZLouOW8,10
16
- chunkr_ai-0.3.6.dist-info/RECORD,,
12
+ chunkr_ai-0.3.7.dist-info/licenses/LICENSE,sha256=w3R12yNDyZpMiy2lxy_hvNbsldC75ww79sF0u11rkho,1069
13
+ chunkr_ai-0.3.7.dist-info/METADATA,sha256=YoDQAJKUKJ6uiYDR9hI7t2BBPFerRQoeTdG8abELN08,7200
14
+ chunkr_ai-0.3.7.dist-info/WHEEL,sha256=_zCd3N1l69ArxyTb8rzEoP9TpbYXkqRFSNOD5OuxnTs,91
15
+ chunkr_ai-0.3.7.dist-info/top_level.txt,sha256=0IZY7PZIiS8bw5r4NUQRUQ-ATi-L_3vLQVq3ZLouOW8,10
16
+ chunkr_ai-0.3.7.dist-info/RECORD,,