Repository navigation
refactor(system): add extendedProperties parameter - #96
cesarcoatl merged 1 commit into
Conversation
system.historian.queryAggregatedPoints
Reviewer's guide (collapsed on small PRs)Reviewer's GuideThe PR extends system.historian.queryAggregatedPoints with an optional, typed extendedProperties dictionary for SQL Historian query options, documenting and forwarding it consistently in both runtime code and type stubs. Sequence diagram for historian query extended propertiessequenceDiagram
participant Caller
participant Historian
participant BasicDataset
Caller->>Historian: queryAggregatedPoints(paths, startDate, endDate, returnSize, extendedProperties)
Historian->>Historian: queryAggregatedPoints(paths, startDate, endDate, aggregationMode, returnFormat, returnSize, extendedProperties)
Historian-->>Caller: BasicDataset()
File-Level Changes
Tips and commandsInteracting with Sourcery
Customizing Your ExperienceAccess your dashboard to:
Getting Help
|
There was a problem hiding this comment.
Hey - I've found 1 issue
Prompt for AI Agents
Please address the comments from this code review:
## Individual Comments
### Comment 1
<location path="stubs/stubs/system/historian/__init__.pyi" line_range="20" />
<code_context>
columnNames: Optional[List[Union[str, unicode]]] = ...,
returnFormat: str = ...,
returnSize: int = ...,
+ extendedProperties: Optional[Dict[Union[str, unicode], Any]] = ...,
) -> BasicDataset: ...
def queryAnnotations(
</code_context>
<issue_to_address>
**New keyword fails type checking**
When a type checker resolves `system.historian` through the root-level or sibling module stub, the stub lacks an `extendedProperties` parameter, so calls passing that keyword are rejected and callers cannot type-check the new API parameter.
Add the `extendedProperties` parameter to the root-level `system.historian` stub to match the package stub.
</issue_to_address>Sourcery assessment
Approval pending. 1 finding to address first.
Blocking findings: stubs/stubs/system/historian/__init__.pyi:20
| columnNames: Optional[List[Union[str, unicode]]] = ..., | ||
| returnFormat: str = ..., | ||
| returnSize: int = ..., | ||
| extendedProperties: Optional[Dict[Union[str, unicode], Any]] = ..., |
There was a problem hiding this comment.
🟡 Medium · New keyword fails type checking
When a type checker resolves system.historian through the root-level or sibling module stub, the stub lacks an extendedProperties parameter, so calls passing that keyword are rejected and callers cannot type-check the new API parameter.
Add the extendedProperties parameter to the root-level system.historian stub to match the package stub.
Prompt for AI agents
In `stubs/stubs/system/historian/__init__.pyi` at line 20:
**New keyword fails type checking**
When a type checker resolves `system.historian` through the root-level or sibling module stub, the stub lacks an `extendedProperties` parameter, so calls passing that keyword are rejected and callers cannot type-check the new API parameter.
Add the `extendedProperties` parameter to the root-level `system.historian` stub to match the package stub.
system.historian.queryAggregatedPoints
Summary by Sourcery
Extend aggregated historian queries with optional SQL Historian properties.
New Features:
Enhancements:
Documentation: