pinexq-client 0.9.0.20241203.1__py3-none-any.whl → 0.9.2.20250317.3__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.
@@ -1,8 +1,22 @@
1
1
  # ruff: noqa: F403, F401
2
- from .sirenaccess import *
3
- from .model.sirenmodels import *
4
- from .model.error import *
5
- from .media_types import *
6
- from .http_headers import *
7
- from .exceptions import *
8
2
  from .base_relations import BaseRelations
3
+ from .exceptions import *
4
+ from .http_headers import Headers
5
+ from .media_types import MediaTypes, SirenClasses
6
+ from .model.error import ProblemDetails
7
+ from .model.sirenmodels import ActionField, Action, EmbeddedLinkEntity, Link, Entity
8
+ from .sirenaccess import (
9
+ ensure_siren_response,
10
+ execute_action,
11
+ execute_action_on_entity,
12
+ get_resource,
13
+ handle_action_result,
14
+ handle_error_response,
15
+ navigate,
16
+ navigate_self,
17
+ upload_binary,
18
+ upload_file,
19
+ upload_json,
20
+ )
21
+ from .enterapi import enter_api
22
+
@@ -1,7 +1,8 @@
1
1
  import httpx
2
2
 
3
3
  from typing import TypeVar, Type
4
- from pinexq_client.core import Entity, get_resource, raise_exception_on_error
4
+ from pinexq_client.core.sirenaccess import get_resource, raise_exception_on_error
5
+ from pinexq_client.core.model.sirenmodels import Entity
5
6
  from pinexq_client.core.hco.hco_base import Hco
6
7
 
7
8
  THco = TypeVar('THco', bound=Hco)
@@ -87,7 +87,7 @@ def upload_file(client: httpx.Client, action: Action, file: BinaryIO, filename:
87
87
  return handle_action_result(response)
88
88
 
89
89
 
90
- def execute_action_on_entity(client: httpx.Client, entity: Entity, name: str, parameters: BaseModel | None = None):
90
+ def execute_action_on_entity(client: httpx.Client, entity: Entity, name: str, parameters: BaseModel | None = None) -> None | URL | ProblemDetails | Response:
91
91
  action = entity.find_first_action_with_name(name)
92
92
  if action is None:
93
93
  raise ClientException(f"Entity does not contain expected action: {name}")
@@ -1,6 +1,25 @@
1
1
  # ruff: noqa: F401
2
2
  from .enterjma import enter_jma
3
- from .tool import Job, ProcessingStep, WorkData
3
+ from .hcos import (
4
+ EntryPointHco,
5
+ InfoHco,
6
+ InputDataSlotHco,
7
+ JobHco,
8
+ JobLink,
9
+ JobQueryResultHco,
10
+ JobStates,
11
+ OutputDataSlotHco,
12
+ ProcessingStepsRootHco,
13
+ ProcessingStepHco,
14
+ ProcessingStepLink,
15
+ ProcessingStepQueryResultHco,
16
+ UserHco,
17
+ WorkDataHco,
18
+ WorkDataLink,
19
+ )
20
+ from .known_relations import Relations
21
+ from .model import JobSortPropertiesSortParameter, ProcessingView
22
+ from .tool import Job, JobGroup, ProcessingStep, WorkData
4
23
 
5
24
  # Protocol version the JMA is using
6
- __jma_version__ = [7, 3, 0]
25
+ __jma_version__ = [7, 3, 1]
@@ -1,13 +1,17 @@
1
- from .input_dataslot_hco import *
2
- from .output_dataslot_hco import *
3
1
  from .entrypoint_hco import *
4
2
  from .info_hco import *
3
+ from .input_dataslot_hco import *
5
4
  from .job_hco import *
6
5
  from .job_query_result_hco import *
6
+ from .job_used_tags_hco import *
7
7
  from .jobsroot_hco import *
8
+ from .output_dataslot_hco import *
8
9
  from .processing_step_hco import *
10
+ from .processing_step_used_tags_hco import *
9
11
  from .processingstep_query_result_hco import *
10
12
  from .processingsteproot_hco import *
13
+ from .user_hco import *
11
14
  from .workdata_hco import *
12
15
  from .workdata_query_result_hco import *
16
+ from .workdata_used_tags_query_result_hco import *
13
17
  from .workdataroot_hco import *
@@ -1 +1,2 @@
1
1
  from .open_api_generated import *
2
+ from .sirenentities import *
@@ -1,13 +1,14 @@
1
1
  # generated by datamodel-codegen:
2
2
  # filename: openapi.json
3
- # timestamp: 2024-11-27T15:40:27+00:00
3
+ # timestamp: 2024-12-12T14:18:14+00:00
4
4
 
5
5
  from __future__ import annotations
6
6
 
7
+ from datetime import datetime
7
8
  from enum import Enum
8
9
  from typing import Any, List
9
10
 
10
- from pydantic import AwareDatetime, BaseModel, ConfigDict, Field, constr
11
+ from pydantic import BaseModel, ConfigDict, Field, constr
11
12
 
12
13
 
13
14
  class AdminJobQueryResultHtoOpenApiProperties(BaseModel):
@@ -256,8 +257,8 @@ class ProcessingStepHtoOpenApiProperties(BaseModel):
256
257
  is_public: bool | None = Field(None, alias='IsPublic')
257
258
  tags: List[str] | None = Field(None, alias='Tags')
258
259
  is_configured: bool | None = Field(None, alias='IsConfigured')
259
- created_at: AwareDatetime | None = Field(None, alias='CreatedAt')
260
- last_modified_at: AwareDatetime | None = Field(None, alias='LastModifiedAt')
260
+ created_at: datetime | None = Field(None, alias='CreatedAt')
261
+ last_modified_at: datetime | None = Field(None, alias='LastModifiedAt')
261
262
  parameter_schema: str | None = Field(None, alias='ParameterSchema')
262
263
  default_parameters: str | None = Field(None, alias='DefaultParameters')
263
264
  return_schema: str | None = Field(None, alias='ReturnSchema')
@@ -311,6 +312,7 @@ class ProcessingView(BaseModel):
311
312
  title: str | None = Field(None, alias='Title')
312
313
  description: str | None = Field(None, alias='Description')
313
314
  function_name: str | None = Field(None, alias='FunctionName')
315
+ version: str | None = Field(None, alias='Version')
314
316
  number_of_input_data_slots: int | None = Field(None, alias='NumberOfInputDataSlots')
315
317
  number_of_output_data_slots: int | None = Field(
316
318
  None, alias='NumberOfOutputDataSlots'
@@ -322,7 +324,7 @@ class RenameJobParameters(BaseModel):
322
324
  extra='allow',
323
325
  populate_by_name=True,
324
326
  )
325
- new_name: constr(min_length=1) = Field(..., alias='NewName')
327
+ new_name: constr(min_length=0) = Field("", alias='NewName')
326
328
 
327
329
 
328
330
  class SelectProcessingParameters(BaseModel):
@@ -495,8 +497,8 @@ class AdminJobFilterParameter(BaseModel):
495
497
  state: JobStates | None = Field(None, alias='State')
496
498
  show_hidden: bool | None = Field(None, alias='ShowHidden')
497
499
  processing_step_url: str | None = Field(None, alias='ProcessingStepUrl')
498
- created_before: AwareDatetime | None = Field(None, alias='CreatedBefore')
499
- created_after: AwareDatetime | None = Field(None, alias='CreatedAfter')
500
+ created_before: datetime | None = Field(None, alias='CreatedBefore')
501
+ created_after: datetime | None = Field(None, alias='CreatedAfter')
500
502
  tags_by_and: List[str] | None = Field(None, alias='TagsByAnd')
501
503
  tags_by_or: List[str] | None = Field(None, alias='TagsByOr')
502
504
  parent_job_url: str | None = Field(None, alias='ParentJobUrl')
@@ -562,8 +564,8 @@ class AdminWorkDataFilterParameter(BaseModel):
562
564
  tags_by_and: List[str] | None = Field(None, alias='TagsByAnd')
563
565
  tags_by_or: List[str] | None = Field(None, alias='TagsByOr')
564
566
  is_kind: WorkDataKind | None = Field(None, alias='IsKind')
565
- created_before: AwareDatetime | None = Field(None, alias='CreatedBefore')
566
- created_after: AwareDatetime | None = Field(None, alias='CreatedAfter')
567
+ created_before: datetime | None = Field(None, alias='CreatedBefore')
568
+ created_after: datetime | None = Field(None, alias='CreatedAfter')
567
569
  is_deletable: bool | None = Field(None, alias='IsDeletable')
568
570
  is_used: bool | None = Field(None, alias='IsUsed')
569
571
 
@@ -627,8 +629,8 @@ class JobFilterParameter(BaseModel):
627
629
  name: str | None = Field(None, alias='Name')
628
630
  show_hidden: bool | None = Field(None, alias='ShowHidden')
629
631
  work_data_url: str | None = Field(None, alias='WorkDataUrl')
630
- created_before: AwareDatetime | None = Field(None, alias='CreatedBefore')
631
- created_after: AwareDatetime | None = Field(None, alias='CreatedAfter')
632
+ created_before: datetime | None = Field(None, alias='CreatedBefore')
633
+ created_after: datetime | None = Field(None, alias='CreatedAfter')
632
634
  tags_by_and: List[str] | None = Field(None, alias='TagsByAnd')
633
635
  tags_by_or: List[str] | None = Field(None, alias='TagsByOr')
634
636
  processing_step_url: str | None = Field(None, alias='ProcessingStepUrl')
@@ -646,8 +648,8 @@ class JobHtoOpenApiProperties(BaseModel):
646
648
  tags: List[str] | None = Field(None, alias='Tags')
647
649
  hidden: bool | None = Field(None, alias='Hidden')
648
650
  output_is_deletable: bool | None = Field(None, alias='OutputIsDeletable')
649
- created_at: AwareDatetime | None = Field(None, alias='CreatedAt')
650
- completed_at: AwareDatetime | None = Field(None, alias='CompletedAt')
651
+ created_at: datetime | None = Field(None, alias='CreatedAt')
652
+ completed_at: datetime | None = Field(None, alias='CompletedAt')
651
653
  error_description: str | None = Field(None, alias='ErrorDescription')
652
654
  processing: ProcessingView | None = Field(None, alias='Processing')
653
655
  result: str | None = Field(None, alias='Result')
@@ -792,8 +794,8 @@ class WorkDataFilterParameter(BaseModel):
792
794
  tags_by_and: List[str] | None = Field(None, alias='TagsByAnd')
793
795
  tags_by_or: List[str] | None = Field(None, alias='TagsByOr')
794
796
  is_kind: WorkDataKind | None = Field(None, alias='IsKind')
795
- created_before: AwareDatetime | None = Field(None, alias='CreatedBefore')
796
- created_after: AwareDatetime | None = Field(None, alias='CreatedAfter')
797
+ created_before: datetime | None = Field(None, alias='CreatedBefore')
798
+ created_after: datetime | None = Field(None, alias='CreatedAfter')
797
799
  is_deletable: bool | None = Field(None, alias='IsDeletable')
798
800
  is_used: bool | None = Field(None, alias='IsUsed')
799
801
 
@@ -804,7 +806,7 @@ class WorkDataHtoOpenApiProperties(BaseModel):
804
806
  populate_by_name=True,
805
807
  )
806
808
  name: str | None = Field(None, alias='Name')
807
- created_at: AwareDatetime | None = Field(None, alias='CreatedAt')
809
+ created_at: datetime | None = Field(None, alias='CreatedAt')
808
810
  size_in_bytes: int | None = Field(None, alias='SizeInBytes')
809
811
  tags: List[str] | None = Field(None, alias='Tags')
810
812
  media_type: str | None = Field(None, alias='MediaType')
@@ -79,12 +79,14 @@ class JobUsedTagsEntity(Entity):
79
79
  properties: JobUsedTagsHtoOpenApiProperties | None = None
80
80
 
81
81
 
82
+ # this needs to be added since the openapi.spec does not have this object.
82
83
  class InputDataSlotHtoProperties(BaseModel):
83
84
  model_config = ConfigDict(
84
- extra="forbid",
85
+ extra="allow",
85
86
  populate_by_name=True,
86
87
  )
87
88
  is_configured: bool | None = Field(None, alias="IsConfigured")
89
+ name: str = Field("", alias="Name")
88
90
  title: str | None = Field(None, alias="Title")
89
91
  description: str | None = Field(None, alias="Description")
90
92
  media_type: str | None = Field(None, alias="MediaType")
@@ -94,11 +96,13 @@ class InputDataSlotEntity(Entity):
94
96
  properties: InputDataSlotHtoProperties | None = None
95
97
 
96
98
 
99
+ # this needs to be added since the openapi.spec does not have this object.
97
100
  class OutputDataSlotHtoProperties(BaseModel):
98
101
  model_config = ConfigDict(
99
- extra="forbid",
102
+ extra="allow",
100
103
  populate_by_name=True,
101
104
  )
105
+ name: str = Field("", alias="Name")
102
106
  title: str | None = Field(None, alias="Title")
103
107
  description: str | None = Field(None, alias="Description")
104
108
  media_type: str | None = Field(None, alias="MediaType")
@@ -1,3 +1,4 @@
1
1
  from .job import Job
2
+ from .job_group import JobGroup
2
3
  from .processing_step import ProcessingStep
3
4
  from .workdata import WorkData
@@ -179,6 +179,7 @@ class Job:
179
179
  def select_processing(
180
180
  self,
181
181
  function_name: str | None = None,
182
+ function_version: str | None = None,
182
183
  *,
183
184
  processing_step_link: ProcessingStepLink | None = None,
184
185
  processing_step_instance: ProcessingStep | None = None
@@ -188,6 +189,7 @@ class Job:
188
189
 
189
190
  Args:
190
191
  function_name: Name of the processing step as string
192
+ function_version: Version of the processing step as string
191
193
  processing_step_link: A ProcessingStepLink instance pointing to the resource
192
194
  processing_step_instance: A ProcessingStep (not the Hco) instance
193
195
 
@@ -213,7 +215,8 @@ class Job:
213
215
  query_param = ProcessingStepQueryParameters(
214
216
  filter=ProcessingStepFilterParameter(
215
217
  function_name=function_name,
216
- function_name_match_type=FunctionNameMatchTypes.match_exact
218
+ function_name_match_type=FunctionNameMatchTypes.match_exact,
219
+ function_version=function_version,
217
220
  )
218
221
  )
219
222
  query_result = self._processing_step_root.query_action.execute(query_param)
@@ -3,7 +3,7 @@ from typing import Union, Self
3
3
 
4
4
  import httpx
5
5
 
6
- from pinexq_client.job_management import Job
6
+ from pinexq_client.job_management.tool import Job
7
7
  from pinexq_client.job_management.hcos import JobQueryResultHco
8
8
  from pinexq_client.job_management.model import JobStates
9
9
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: pinexq-client
3
- Version: 0.9.0.20241203.1
3
+ Version: 0.9.2.20250317.3
4
4
  Summary: A hypermedia-based client for the DataCybernetics PinexQ platform.
5
5
  Author-Email: =?utf-8?q?Sebastian_H=C3=B6fer?= <hoefer@data-cybernetics.com>, Mathias Reichardt <reichardt@data-cybernetics.com>, Jasim Ahmed <ahmed@data-cybernetics.com>, Pratik Poudel <poudel@data-cybernetics.com>
6
6
  Maintainer-Email: Mathias Reichardt <reichardt@data-cybernetics.com>, =?utf-8?q?Sebastian_H=C3=B6fer?= <hoefer@data-cybernetics.com>, Carsten Blank <blank@data-cybernetics.com>
@@ -1,10 +1,10 @@
1
- pinexq_client-0.9.0.20241203.1.dist-info/METADATA,sha256=YJLPPrztDSpMg_ewegmfvz1wfB_WAfuSxJ6EM4TPGyo,3278
2
- pinexq_client-0.9.0.20241203.1.dist-info/WHEEL,sha256=thaaA2w1JzcGC48WYufAs8nrYZjJm8LqNfnXFOFyCC4,90
3
- pinexq_client-0.9.0.20241203.1.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
4
- pinexq_client-0.9.0.20241203.1.dist-info/licenses/LICENSE,sha256=3oz3tAhM7kOgRukkRe7wmh5T_HihZY77ZtJDJm91ZN8,1072
5
- pinexq_client/core/__init__.py,sha256=8SVD_PRgJtpUCOtVjdR6fRrv6KPNk7HD6UQrn0FKR04,235
1
+ pinexq_client-0.9.2.20250317.3.dist-info/METADATA,sha256=5NfTjM2ZTozjLvus0zcPMkXPZBDqss7G_fOzQ1IeyRA,3278
2
+ pinexq_client-0.9.2.20250317.3.dist-info/WHEEL,sha256=thaaA2w1JzcGC48WYufAs8nrYZjJm8LqNfnXFOFyCC4,90
3
+ pinexq_client-0.9.2.20250317.3.dist-info/entry_points.txt,sha256=6OYgBcLyFCUgeqLgnvMyOJxPCWzgy7se4rLPKtNonMs,34
4
+ pinexq_client-0.9.2.20250317.3.dist-info/licenses/LICENSE,sha256=3oz3tAhM7kOgRukkRe7wmh5T_HihZY77ZtJDJm91ZN8,1072
5
+ pinexq_client/core/__init__.py,sha256=zO9vUuAl6AEokL-SqQO3Jl1qrxFBZPA2kH99VNZugEU,598
6
6
  pinexq_client/core/base_relations.py,sha256=oIUS58pkbMDdqm-3YOdsenhL1smtzeAk4fp7-U595MY,162
7
- pinexq_client/core/enterapi.py,sha256=sL9TmF1L5LaDJnre1l_tiHDUo9vTbZ8cvPSov3Q1UTs,671
7
+ pinexq_client/core/enterapi.py,sha256=eB4F2_t3lCbMgKhy-M-Sf_u9MhuJMO7OGh-GB-4Cc-8,731
8
8
  pinexq_client/core/exceptions.py,sha256=NqB3y1ufjOfG3kv7Rz4ppXqJRAugt2zlgxkto2nIVQU,2228
9
9
  pinexq_client/core/hco/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
10
10
  pinexq_client/core/hco/action_hco.py,sha256=6bWea-SkFjn52m5sYywkZeNOe74Nxmsvj338jSB6RZo,2338
@@ -20,10 +20,10 @@ pinexq_client/core/model/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZ
20
20
  pinexq_client/core/model/error.py,sha256=ZDbUlwsj7d8XPMolSSLTFwgs3RBLvOvgmlEtoBuon5Y,418
21
21
  pinexq_client/core/model/sirenmodels.py,sha256=vGRQlhM2cSa2caxQel91Jr48KWqM-vMYX32iaQCzIds,5547
22
22
  pinexq_client/core/polling.py,sha256=Z6VXn-PCGk4XX-4tQWZG59qJyCIS0eIrpPUORQDIGrs,1077
23
- pinexq_client/core/sirenaccess.py,sha256=qopQKDfL1enJFb0Ja8UgsLMVOa0oBGy7PonhlV7YVBY,6950
24
- pinexq_client/job_management/__init__.py,sha256=r-Hgjon5a7uvuj1x3rSf3btMjG28xcQqnvaVEsEksw8,164
23
+ pinexq_client/core/sirenaccess.py,sha256=F7eZI5Pz79el0D30SYNGsiS2qWaAZF_jrCrUy-q2GgY,6992
24
+ pinexq_client/job_management/__init__.py,sha256=iv5oNaGoBlgSEZbUZxIRqtYrPsQce2Mm28sv98EwQiM,598
25
25
  pinexq_client/job_management/enterjma.py,sha256=Ivl_jVPw_gaLyU5nKbywM-bbVGpn0MoCrZ0DMbJYf3s,1411
26
- pinexq_client/job_management/hcos/__init__.py,sha256=sjRsC3FDCfTLtfUM7j-6wic26ELlYdPNDjrOPLFiKjE,431
26
+ pinexq_client/job_management/hcos/__init__.py,sha256=TZgs5kuBk3lSBxPfn5ehgbdUgzPy2jn1PC3Ea6VQY-k,584
27
27
  pinexq_client/job_management/hcos/entrypoint_hco.py,sha256=qodjAwO_MtawUuhmaYjhGXHV-uW1k94V9gKRYZRkhn4,2234
28
28
  pinexq_client/job_management/hcos/info_hco.py,sha256=zWjR63SCEO_sUcZ9ha_aIoC_qUzAWLf50Xu4AHddAn8,1328
29
29
  pinexq_client/job_management/hcos/input_dataslot_hco.py,sha256=SDflhyW8kjpcTUfKAXnJxNR-etPzAHfoTqlYUcJZrxs,3442
@@ -42,12 +42,12 @@ pinexq_client/job_management/hcos/workdata_query_result_hco.py,sha256=yxEnu_COMx
42
42
  pinexq_client/job_management/hcos/workdata_used_tags_query_result_hco.py,sha256=qB1iQpwD63579dq3tUF4DBB_rZRMqJ80y1ysf-41aOo,1087
43
43
  pinexq_client/job_management/hcos/workdataroot_hco.py,sha256=LdEPW2JJTqAWi-6zj-40lfREhthcDL6nPXQk_nfMtCA,3936
44
44
  pinexq_client/job_management/known_relations.py,sha256=f3-7RagAfeSFv9b54l5zxnLKbVQjQQHzYsM4W2QHf0Y,708
45
- pinexq_client/job_management/model/__init__.py,sha256=ApHhNfjx4bPuz10sQnyBA2zajYbU7loDTZSKC5H_jBY,34
46
- pinexq_client/job_management/model/open_api_generated.py,sha256=BxSGNyJDbr6x-LKCELGg3Mctn0TZasKYEQ2aOHLFqjo,31458
47
- pinexq_client/job_management/model/sirenentities.py,sha256=OInvxHpC6mnnYQjOMM2xAw7uLtvWwj9E2EQSRJe2jDo,3202
48
- pinexq_client/job_management/tool/__init__.py,sha256=58CRDcP8ifSx9eA2uyTLEg0_fX3FUuNUogY_lirx9AY,96
49
- pinexq_client/job_management/tool/job.py,sha256=_4HKeOAXsVx9f3DR-2E2Oyr3RqGqEb3Am4D1HwFh9JI,24795
50
- pinexq_client/job_management/tool/job_group.py,sha256=JyBKqtKAMpVXwdGaGKzh5IJOHgMk8zhK9b54jfvEHkk,4817
45
+ pinexq_client/job_management/model/__init__.py,sha256=iuAKRXdW_Mxo0i3HsBfEzhJJZUKkNe3qs4gLW-ge1PU,63
46
+ pinexq_client/job_management/model/open_api_generated.py,sha256=FP1dLyt53QjQySa42Cx3Db81xb1f07jNCGnDY9Ppu9Y,31462
47
+ pinexq_client/job_management/model/sirenentities.py,sha256=MUjgByEwzQcrduCEJuNK85uAj8SLTdyaiKmnlB44h3E,3430
48
+ pinexq_client/job_management/tool/__init__.py,sha256=zPobd-hQyANHzC0-TjJG91z9XrewvE54ZJ6VViymW5M,128
49
+ pinexq_client/job_management/tool/job.py,sha256=EQl98STgyjxdDoy9n2dC16rFG2EZYA2PX4rfmebT3qw,24971
50
+ pinexq_client/job_management/tool/job_group.py,sha256=TNWw46UDyP2gmArhbzMAqpHa6lS2hzwarLIrxxpOMnk,4822
51
51
  pinexq_client/job_management/tool/processing_step.py,sha256=OOm36tV_N9RnJKh9WBZo_Xbmg1kb5JKh0NtNfECrNpM,10286
52
52
  pinexq_client/job_management/tool/workdata.py,sha256=wRy_yfFZUJDh-hoGUuAbQaRGtPysDmEOhLwD84Fgz04,5510
53
- pinexq_client-0.9.0.20241203.1.dist-info/RECORD,,
53
+ pinexq_client-0.9.2.20250317.3.dist-info/RECORD,,