Skip to content

Commit

Permalink
Merge pull request #8 from waylayio/chore/regenerate
Browse files Browse the repository at this point in the history
Regenerate rules sdk 🔁
  • Loading branch information
plankthom authored Aug 2, 2024
2 parents 1307024 + 767b0b0 commit a7b8bfa
Show file tree
Hide file tree
Showing 25 changed files with 68 additions and 60 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -133,4 +133,4 @@ jobs:
- name: Publish to PyPI
uses: pypa/gh-action-pypi-publish@release/v1
with:
packages-dir: waylay-sdk-rules-types/dist
packages-dir: waylay-sdk-rules-types/dist
2 changes: 1 addition & 1 deletion .openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.2.0
7.7.0
17 changes: 10 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,16 @@ It consists of two sub-packages that are both plugins for the waylay-sdk-core pa
This package requires Python 3.9+.

## Installation
Typically this package is installed when installing the [waylay-sdk-core](https://pypi.org/project/waylay-sdk/) package to enable the service's functionality.
When the service api methods are required, waylay-sdk-rules is included in:
- ```pip install waylay-sdk-core[rules]``` to install `waylay-sdk-core` along with only this service, or
- ```pip install waylay-sdk-core[services]``` to install `waylay-sdk-core` along with all services.
When the typed models are required, both waylay-sdk-rules and waylay-sdk-rules-types are included in:
- ```pip install waylay-sdk-core[rules,rules-types]``` to install `waylay-sdk-core` along with only this service including the typed models, or
- ```pip install waylay-sdk-core[services,services-types]``` to install `waylay-sdk-core` along with all services along with the typed models.

Normally this package is installed together with support for other services using the [waylay-sdk](https://pypi.org/project/waylay-sdk/) umbrella package:
* `pip install waylay-sdk` will install `waylay-sdk-rules` together with the SDK api packages for other services.
* `pip install waylay-sdk[types-rules]` will additionally install the types package `waylay-sdk-rules-types`.
* `pip install waylay-sdk[types]` will install the types packages for this and all other services.

Alternatively, you can install support for this _rules_ service only, installing or extending an existing [waylay-sdk-core](https://pypi.org/project/waylay-sdk-core/):

- `pip install waylay-sdk-rules` to only install api support for _rules_.
- `pip install waylay-sdk-rules[types]` to additionally install type support for _rules_.

## Usage

Expand Down
2 changes: 1 addition & 1 deletion docs/PluginUpdateSpec.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**name** | **str** | Name of the plugin to update |
**from_version** | [**PluginUpdateSpecFromVersion**](PluginUpdateSpecFromVersion.md) | |
**to_version** | **str** | |
**to_version** | **str** | Plugin version to upgrade to |

## Example

Expand Down
6 changes: 3 additions & 3 deletions docs/TasksApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ Name | Type | API binding | Description | Notes
-------- | ----- | ------------- | ------------- | -------------
**task_id** | **str** | path parameter `"taskId"` | Unique Task identifier |
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional]
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional] [default bn]
**headers** | [HeaderTypes](Operation.md#req_headers) | request headers | |

### Return type
Expand Down Expand Up @@ -285,7 +285,7 @@ Name | Type | API binding | Description | Notes
-------- | ----- | ------------- | ------------- | -------------
**task_id** | **str** | path parameter `"taskId"` | Unique Task identifier |
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional]
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional] [default bn]
**headers** | [HeaderTypes](Operation.md#req_headers) | request headers | |

### Return type
Expand Down Expand Up @@ -371,7 +371,7 @@ Name | Type | API binding | Description | Notes
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['hits']** (dict) <br> **query.hits** (Query) | **int** | query parameter `"hits"` | (Paging) maximal number of items returned | [optional] [default 10]
**query['startIndex']** (dict) <br> **query.start_index** (Query) | **int** | query parameter `"startIndex"` | (Paging) items to skip in the listing | [optional] [default 0]
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional]
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional] [default bn]
**query['name']** (dict) <br> **query.name** (Query) | **str** | query parameter `"name"` | | [optional]
**query['resource']** (dict) <br> **query.resource** (Query) | **str** | query parameter `"resource"` | | [optional]
**query['resourceType']** (dict) <br> **query.resource_type** (Query) | **str** | query parameter `"resourceType"` | | [optional]
Expand Down
4 changes: 2 additions & 2 deletions docs/TemplateRunsApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ Name | Type | API binding | Description | Notes
-------- | ----- | ------------- | ------------- | -------------
**json** | [**TemplateRunWithGraphSpecification**](TemplateRunWithGraphSpecification.md) | json request body | Specification to run template through graph/BN. |
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['logLevel']** (dict) <br> **query.log_level** (Query) | [**RunTemplateLogLevelParameter**](.md) | query parameter `"logLevel"` | sets the log level for filtering out logs to requested log level or higher from the template run output. Value &#x60;NONE&#x60; will disable all logs. If not specified all logs will be returned. | [optional]
**query['logLevel']** (dict) <br> **query.log_level** (Query) | [**RunTemplateLogLevelParameter**](.md) | query parameter `"logLevel"` | sets the log level for filtering out logs to requested log level or higher from the template run output. Value &#x60;NONE&#x60; will disable all logs. If not specified all logs will be returned. | [optional] [default DEBUG]
**query['targetNode']** (dict) <br> **query.target_node** (Query) | [**List[str]**](str.md) | query parameter `"targetNode"` | The sensors and actuators part of response will contain only elements related to the asked node of the graph. The returned logs also will be filtered and contain only logs related to the asked node(s). | [optional]
**headers** | [HeaderTypes](Operation.md#req_headers) | request headers | |

Expand Down Expand Up @@ -140,7 +140,7 @@ Name | Type | API binding | Description | Notes
**name** | **str** | path parameter `"name"` | Unique Template identifier |
**json** | [**TemplateRunSpecification**](TemplateRunSpecification.md) | json request body | Specification to run template |
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['logLevel']** (dict) <br> **query.log_level** (Query) | [**RunTemplateLogLevelParameter**](.md) | query parameter `"logLevel"` | sets the log level for filtering out logs to requested log level or higher from the template run output. Value &#x60;NONE&#x60; will disable all logs. If not specified all logs will be returned. | [optional]
**query['logLevel']** (dict) <br> **query.log_level** (Query) | [**RunTemplateLogLevelParameter**](.md) | query parameter `"logLevel"` | sets the log level for filtering out logs to requested log level or higher from the template run output. Value &#x60;NONE&#x60; will disable all logs. If not specified all logs will be returned. | [optional] [default DEBUG]
**query['targetNode']** (dict) <br> **query.target_node** (Query) | [**List[str]**](str.md) | query parameter `"targetNode"` | The sensors and actuators part of response will contain only elements related to the asked node of the graph. The returned logs also will be filtered and contain only logs related to the asked node(s). | [optional]
**headers** | [HeaderTypes](Operation.md#req_headers) | request headers | |

Expand Down
2 changes: 1 addition & 1 deletion docs/TemplatesApi.md
Original file line number Diff line number Diff line change
Expand Up @@ -266,7 +266,7 @@ Name | Type | API binding | Description | Notes
-------- | ----- | ------------- | ------------- | -------------
**name** | **str** | path parameter `"name"` | Unique Template identifier |
**query** | [QueryParamTypes](Operation.md#req_arg_query) \| **None** | URL query parameter | |
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional]
**query['format']** (dict) <br> **query.format** (Query) | [**ListTasksFormatParameter**](.md) | query parameter `"format"` | Format of the graph definition | [optional] [default bn]
**headers** | [HeaderTypes](Operation.md#req_headers) | request headers | |

### Return type
Expand Down
1 change: 0 additions & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,6 @@
include = ["pyproject.toml", "test/**/*.py"]

[tool.ruff.lint]
ignore-init-module-imports = true
# allow duplicate imports
ignore=["F811"]
# https://docs.astral.sh/ruff/rules
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
pydantic ~= 2.6
typing-extensions ~= 4.9
waylay-sdk-core ~= 0.2.1
waylay-sdk-core ~= 0.2.3
2 changes: 1 addition & 1 deletion waylay-sdk-rules-types/.openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.2.0
7.7.0
17 changes: 10 additions & 7 deletions waylay-sdk-rules-types/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -11,13 +11,16 @@ It is considered an extension of the waylay-sdk-rules package, and it consists o
This package requires Python 3.9+.

## Installation
Typically this package is installed when installing the [waylay-sdk-core](https://pypi.org/project/waylay-sdk/) package to enable the service's functionality.
When the service api methods are required, waylay-sdk-rules is included in:
- ```pip install waylay-sdk-core[rules]``` to install `waylay-sdk-core` along with only this service, or
- ```pip install waylay-sdk-core[services]``` to install `waylay-sdk-core` along with all services.
When the typed models are required, both waylay-sdk-rules and waylay-sdk-rules-types are included in:
- ```pip install waylay-sdk-core[rules,rules-types]``` to install `waylay-sdk-core` along with only this service including the typed models, or
- ```pip install waylay-sdk-core[services,services-types]``` to install `waylay-sdk-core` along with all services along with the typed models.

Normally this package is installed together with support for other services using the [waylay-sdk](https://pypi.org/project/waylay-sdk/) umbrella package:
* `pip install waylay-sdk` will install `waylay-sdk-rules` together with the SDK api packages for other services.
* `pip install waylay-sdk[types-rules]` will additionally install the types package `waylay-sdk-rules-types`.
* `pip install waylay-sdk[types]` will install the types packages for this and all other services.

Alternatively, you can install support for this _rules_ service only, installing or extending an existing [waylay-sdk-core](https://pypi.org/project/waylay-sdk-core/):

- `pip install waylay-sdk-rules` to only install api support for _rules_.
- `pip install waylay-sdk-rules[types]` to additionally install type support for _rules_.

## Usage

Expand Down
7 changes: 3 additions & 4 deletions waylay-sdk-rules-types/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,16 +4,16 @@ build-backend = "setuptools.build_meta"

[project]
name = "waylay-sdk-rules-types"
version = "6.5.0.20240430"
version = "6.5.0.20240802"
description = "Waylay rules engine Types "
authors = [
{ name = "Waylay", email = "[email protected]"}
]
keywords = ["Waylay rules engine" , "Types"]
requires-python = ">= 3.9"
dependencies = [
"waylay-sdk-core ~= 0.2.1",
"waylay-sdk-rules == 6.5.0.20240430",
"waylay-sdk-core ~= 0.2.3",
"waylay-sdk-rules == 6.5.0.20240802",
"pydantic ~= 2.6",
"typing-extensions ~= 4.10",
"eval-type-backport ~= 0.1.3; python_version < '3.10'",
Expand Down Expand Up @@ -54,7 +54,6 @@ namespaces = true
include = ["pyproject.toml", "src/**/*.py"]

[tool.ruff.lint]
ignore-init-module-imports = true
# allow duplicate imports
ignore=["F811"]
# https://docs.astral.sh/ruff/rules
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
Do not edit the class manually.
"""

__version__ = "6.5.0.20240430"
__version__ = "6.5.0.20240802"

# import models into model package
from .a_tasks_batch_operation_specification import ATasksBatchOperationSpecification
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,9 @@ class PluginUpdateSpec(WaylayBaseModel):

name: StrictStr = Field(description="Name of the plugin to update")
from_version: PluginUpdateSpecFromVersion = Field(alias="fromVersion")
to_version: Annotated[str, Field(strict=True)] = Field(alias="toVersion")
to_version: Annotated[str, Field(strict=True)] = Field(
description="Plugin version to upgrade to", alias="toVersion"
)

@field_validator("to_version")
@classmethod
Expand Down
2 changes: 1 addition & 1 deletion waylay-sdk-rules/.openapi-generator/VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
7.2.0
7.7.0
17 changes: 10 additions & 7 deletions waylay-sdk-rules/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,13 +12,16 @@ Note that the typed model classes for all path params, query params, body params
This package requires Python 3.9+.

## Installation
Typically this package is installed when installing the [waylay-sdk-core](https://pypi.org/project/waylay-sdk/) package to enable the service's functionality.
When the service api methods are required, waylay-sdk-rules is included in:
- ```pip install waylay-sdk-core[rules]``` to install `waylay-sdk-core` along with only this service, or
- ```pip install waylay-sdk-core[services]``` to install `waylay-sdk-core` along with all services.
When the typed models are required, both waylay-sdk-rules and waylay-sdk-rules-types are included in:
- ```pip install waylay-sdk-core[rules,rules-types]``` to install `waylay-sdk-core` along with only this service including the typed models, or
- ```pip install waylay-sdk-core[services,services-types]``` to install `waylay-sdk-core` along with all services along with the typed models.

Normally this package is installed together with support for other services using the [waylay-sdk](https://pypi.org/project/waylay-sdk/) umbrella package:
* `pip install waylay-sdk` will install `waylay-sdk-rules` together with the SDK api packages for other services.
* `pip install waylay-sdk[types-rules]` will additionally install the types package `waylay-sdk-rules-types`.
* `pip install waylay-sdk[types]` will install the types packages for this and all other services.

Alternatively, you can install support for this _rules_ service only, installing or extending an existing [waylay-sdk-core](https://pypi.org/project/waylay-sdk-core/):

- `pip install waylay-sdk-rules` to only install api support for _rules_.
- `pip install waylay-sdk-rules[types]` to additionally install type support for _rules_.

## Usage

Expand Down
5 changes: 2 additions & 3 deletions waylay-sdk-rules/pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@ build-backend = "setuptools.build_meta"

[project]
name = "waylay-sdk-rules"
version = "6.5.0.20240430"
version = "6.5.0.20240802"
description = "Waylay rules engine"
authors = [
{ name = "Waylay", email = "[email protected]"}
]
keywords = ["Waylay rules engine"]
requires-python = ">= 3.9"
dependencies = [
"waylay-sdk-core ~= 0.2.1",
"waylay-sdk-core ~= 0.2.3",
"pydantic ~= 2.6",
"typing-extensions ~= 4.10",
"eval-type-backport ~= 0.1.3; python_version < '3.10'",
Expand Down Expand Up @@ -57,7 +57,6 @@ namespaces = true
include = ["pyproject.toml", "src/**/*.py"]

[tool.ruff.lint]
ignore-init-module-imports = true
# allow duplicate imports
ignore=["F811"]
# https://docs.astral.sh/ruff/rules
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ async def execute_actuator(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down Expand Up @@ -496,7 +496,7 @@ async def execute_actuator_version(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down Expand Up @@ -682,7 +682,7 @@ async def execute_sensor(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down Expand Up @@ -889,7 +889,7 @@ async def execute_sensor_version(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down Expand Up @@ -1075,7 +1075,7 @@ async def execute_transformer(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down Expand Up @@ -1282,7 +1282,7 @@ async def execute_transformer_version(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ExecutePlugsSpecification,
Field(description="Specification to execute a plug."),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -198,7 +198,7 @@ async def push(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
StreamData, Field(description="Push (real-time) Data Specification")
]
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -543,7 +543,7 @@ async def patch(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(NodeStateSpecification)
body_adapter: Any = TypeAdapter(NodeStateSpecification)
json = body_adapter.validate_python(json) # type: ignore # https://github.com/pydantic/pydantic/discussions/7094
body_args["json"] = json

Expand Down
4 changes: 2 additions & 2 deletions waylay-sdk-rules/src/waylay/services/rules/api/tasks_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ async def create(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[TaskSpecification, Field(description="Task Specification")]
)
json = body_adapter.validate_python(json) # type: ignore # https://github.com/pydantic/pydantic/discussions/7094
Expand Down Expand Up @@ -1053,7 +1053,7 @@ async def replace(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[TaskSpecification, Field(description="Task Specification")]
)
json = body_adapter.validate_python(json) # type: ignore # https://github.com/pydantic/pydantic/discussions/7094
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -389,7 +389,7 @@ async def start(
## named body parameters
body_args: Dict[str, Any] = {}
if json is not None and validate_request:
body_adapter = TypeAdapter(
body_adapter: Any = TypeAdapter(
Annotated[
ATasksBatchOperationSpecification,
Field(description="Tasks Batch Operation"),
Expand Down
Loading

0 comments on commit a7b8bfa

Please sign in to comment.