Skip to content

Commit 9933855

Browse files
authored
Merge pull request #1118 from ie3-institute/df/#1117-validationUtils
Use ValidationUtils for ThermalGrids
2 parents 193194b + ef4ce9b commit 9933855

File tree

2 files changed

+6
-1
lines changed

2 files changed

+6
-1
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -57,6 +57,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
5757
- Replace `PvModel` with its new implementation [#1149](https://github.com/ie3-institute/simona/issues/1149)
5858
- Replace `WecModel` with its new implementation [#1154](https://github.com/ie3-institute/simona/issues/1154)
5959
- Replace `StorageModel` with its new implementation [#1153](https://github.com/ie3-institute/simona/issues/1153)
60+
- Use ValidationUtils for ThermalGrids [#1117](https://github.com/ie3-institute/simona/issues/1117)
6061

6162
### Changed
6263
- Adapted to changed data source in PSDM [#435](https://github.com/ie3-institute/simona/issues/435)

src/main/scala/edu/ie3/simona/io/grid/GridProvider.scala

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,12 @@ object GridProvider extends LazyLogging {
100100
new FileNamingStrategy(),
101101
)
102102
.asScala
103-
.map(thermalGrid => thermalGrid.bus() -> thermalGrid)
103+
.map { thermalGrid =>
104+
ValidationUtils.check(thermalGrid)
105+
thermalGrid.bus() -> thermalGrid
106+
}
104107
.toMap
108+
105109
case None =>
106110
throw new RuntimeException(
107111
"CSVGridSource requires csv params to be set!"

0 commit comments

Comments
 (0)