kodexa 7.0.9209424800__tar.gz → 7.0.9596368033__tar.gz

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.
Files changed (44) hide show
  1. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/PKG-INFO +1 -1
  2. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/model.py +7 -3
  3. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/objects.py +1 -1
  4. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/platform/client.py +8 -1
  5. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/pyproject.toml +1 -1
  6. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/LICENSE +0 -0
  7. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/README.md +0 -0
  8. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/__init__.py +0 -0
  9. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/assistant/__init__.py +0 -0
  10. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/assistant/assistant.py +0 -0
  11. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/connectors/__init__.py +0 -0
  12. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/connectors/connectors.py +0 -0
  13. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/__init__.py +0 -0
  14. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/base.py +0 -0
  15. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/entities/__init__.py +0 -0
  16. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/entities/product.py +0 -0
  17. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/entities/product_subscription.py +0 -0
  18. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/model/persistence.py +0 -0
  19. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/pipeline/__init__.py +0 -0
  20. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/pipeline/pipeline.py +0 -0
  21. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/platform/__init__.py +0 -0
  22. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/platform/interaction.py +0 -0
  23. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/platform/kodexa.py +0 -0
  24. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/__init__.py +0 -0
  25. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/ast.py +0 -0
  26. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/core.py +0 -0
  27. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/lexrules.py +0 -0
  28. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/lextab.py +0 -0
  29. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/lextab.pyi +0 -0
  30. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/parserules.py +0 -0
  31. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/parserules.pyi +0 -0
  32. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/parsetab.py +0 -0
  33. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/selectors/parsetab.pyi +0 -0
  34. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/spatial/__init__.py +0 -0
  35. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/spatial/azure_models.py +0 -0
  36. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/spatial/bbox_common.py +0 -0
  37. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/spatial/table_form_common.py +0 -0
  38. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/steps/__init__.py +0 -0
  39. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/steps/common.py +0 -0
  40. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/testing/__init__.py +0 -0
  41. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/testing/test_components.py +0 -0
  42. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/testing/test_utils.py +0 -0
  43. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/training/__init__.py +0 -0
  44. {kodexa-7.0.9209424800 → kodexa-7.0.9596368033}/kodexa/training/train_utils.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: kodexa
3
- Version: 7.0.9209424800
3
+ Version: 7.0.9596368033
4
4
  Summary: Python SDK for the Kodexa Platform
5
5
  Author: Austin Redenbaugh
6
6
  Author-email: austin@kodexa.com
@@ -559,9 +559,13 @@ class ContentNode(object):
559
559
  >>> new_page.add_feature('pagination','pageNum',1)
560
560
  """
561
561
  if self.has_feature(feature_type, name):
562
- raise Exception(
563
- f"Feature {feature_type}:{name} already exists on this node, use set_feature to update"
564
- )
562
+ existing_feature = self.get_feature(feature_type, name)
563
+ if isinstance(existing_feature.value, list):
564
+ existing_feature.value.append(value)
565
+ else:
566
+ existing_feature.value = [existing_feature.value, value]
567
+ self.update_feature(existing_feature)
568
+ return existing_feature
565
569
 
566
570
  # Make sure that we treat the value as list all the time
567
571
  new_feature = ContentFeature(
@@ -1732,7 +1732,7 @@ class ProjectResourcesUpdate(BaseModel):
1732
1732
  store_refs: Optional[List[str]] = Field(None, alias="storeRefs")
1733
1733
  dashboard_refs: Optional[List[str]] = Field(None, alias="dashboardRefs")
1734
1734
  data_form_refs: Optional[List[str]] = Field(None, alias="dataFormRefs")
1735
- guidance_set_refs: Optional[List[str]] = Field(None, alias="guidanceSetRefs")
1735
+ guidance_set_refs: Optional[List[str]] = Field(None, alias="guidanceRefs")
1736
1736
 
1737
1737
 
1738
1738
  class Role1(Enum):
@@ -5432,19 +5432,21 @@ class DocumentStoreEndpoint(StoreEndpoint):
5432
5432
  document_family_response.json()
5433
5433
  ).set_client(self.client)
5434
5434
 
5435
- def stream_query(self, query: str = "*", sort=None):
5435
+ def stream_query(self, query: str = "*", sort=None, limit=None):
5436
5436
  """
5437
5437
  Stream the query for the document family.
5438
5438
 
5439
5439
  Args:
5440
5440
  query (str, optional): The query to run. Defaults to "*".
5441
5441
  sort (str, optional): Sorting order of the query. Defaults to None.
5442
+ limit (int, optional): The maximum number of items to return. Defaults to None.
5442
5443
 
5443
5444
  Returns:
5444
5445
  generator: A generator of the document families.
5445
5446
  """
5446
5447
  page_size = 5
5447
5448
  page = 1
5449
+ number_of_items = 0
5448
5450
 
5449
5451
  if not sort:
5450
5452
  sort = "id"
@@ -5456,7 +5458,12 @@ class DocumentStoreEndpoint(StoreEndpoint):
5456
5458
  if not page_response.content:
5457
5459
  break
5458
5460
  for document_family in page_response.content:
5461
+ number_of_items += 1
5462
+ if limit and number_of_items > limit:
5463
+ break
5464
+
5459
5465
  yield document_family
5466
+
5460
5467
  page += 1
5461
5468
 
5462
5469
  def query(
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "kodexa"
3
- version = "7.0.09209424800"
3
+ version = "7.0.09596368033"
4
4
  description = "Python SDK for the Kodexa Platform"
5
5
  authors = ["Austin Redenbaugh <austin@kodexa.com>", "Philip Dodds <philip@kodexa.com>", "Romar Cablao <rcablao@kodexa.com>", "Amadea Paula Dodds <amadeapaula@kodexa.com>"]
6
6
  readme = "README.md"
File without changes