Skip to content

Commit

Permalink
Add converter mrid to transformators_connected_to_converter
Browse files Browse the repository at this point in the history
Can/will be used to connect converter power given in SSH profile.
  • Loading branch information
leifwar committed Jun 16, 2022
1 parent 566411c commit 5aa5164
Show file tree
Hide file tree
Showing 4 changed files with 5 additions and 4 deletions.
2 changes: 1 addition & 1 deletion cimsparql/__init__.py
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
"""Library for CIM sparql queries"""
__version__ = "1.10.0"
__version__ = "1.10.1"
2 changes: 1 addition & 1 deletion cimsparql/model.py
Original file line number Diff line number Diff line change
Expand Up @@ -486,7 +486,7 @@ def transformers_connected_to_converter(
)
if dry_run:
return self._query_with_header(query)
return self._get_table_and_convert(query, index="mrid")
return self._get_table_and_convert(query, index="converter_mrid")

def ac_lines(
self,
Expand Down
3 changes: 2 additions & 1 deletion cimsparql/queries.py
Original file line number Diff line number Diff line change
Expand Up @@ -519,9 +519,10 @@ def transformers_connected_to_converter(
) -> str:
mrid_subject = "?_mrid"
name = "?name"
variables = ["?mrid", "?t_mrid", name]
variables = ["?mrid", "?t_mrid", "?converter_mrid", name]
converters = [sup.rdf_type_tripler("?volt", converter) for converter in converter_types]
where_list = [
f"?volt {ID_OBJ}.mRID ?converter_mrid",
f"{mrid_subject} {ID_OBJ}.mRID ?mrid",
f"?_t_mrid {ID_OBJ}.mRID ?t_mrid",
sup.rdf_type_tripler(mrid_subject, "cim:PowerTransformer"),
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
# character.
[tool.poetry]
name = "cimsparql"
version = "1.10.0"
version = "1.10.1"
description = "CIM query utilities"
readme = "README.md"
authors = ["Statnett Datascience <Datascience.Drift@Statnett.no>"]
Expand Down

0 comments on commit 5aa5164

Please sign in to comment.