From 14e880010c674094beb258e9fbae2bca4a5f4491 Mon Sep 17 00:00:00 2001 From: staudtMarius Date: Tue, 23 Jan 2024 12:11:05 +0100 Subject: [PATCH 1/4] Remove CsvDataSource workaround --- CHANGELOG.md | 1 + .../service/weather/WeatherSource.scala | 5 ++--- .../util/scala/io/CsvDataSourceAdapter.java | 19 ------------------- .../util/scala/io/GraphicDataCleaner.scala | 2 +- 4 files changed, 4 insertions(+), 23 deletions(-) delete mode 100644 src/main/scala/edu/ie3/util/scala/io/CsvDataSourceAdapter.java diff --git a/CHANGELOG.md b/CHANGELOG.md index 65f07e90da..52dd570404 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -33,6 +33,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0 - Removed a repeated line in the documentation of vn_simona config [#658](https://github.com/ie3-institute/simona/issues/658) - Removed version number "2.0" from the logo printed to console [#642](https://github.com/ie3-institute/simona/issues/642) - Fixed PV Model documentation [#684](https://github.com/ie3-institute/simona/issues/684), [#686](https://github.com/ie3-institute/simona/issues/686) +- Removed `CsvDataSourceAdapter` workaround [#702](https://github.com/ie3-institute/simona/issues/702) ## [3.0.0] - 2023-08-07 diff --git a/src/main/scala/edu/ie3/simona/service/weather/WeatherSource.scala b/src/main/scala/edu/ie3/simona/service/weather/WeatherSource.scala index 14838d6afb..eb7262560c 100644 --- a/src/main/scala/edu/ie3/simona/service/weather/WeatherSource.scala +++ b/src/main/scala/edu/ie3/simona/service/weather/WeatherSource.scala @@ -15,7 +15,7 @@ import edu.ie3.datamodel.io.factory.timeseries.{ } import edu.ie3.datamodel.io.naming.FileNamingStrategy import edu.ie3.datamodel.io.source.IdCoordinateSource -import edu.ie3.datamodel.io.source.csv.CsvIdCoordinateSource +import edu.ie3.datamodel.io.source.csv.{CsvDataSource, CsvIdCoordinateSource} import edu.ie3.datamodel.io.source.sql.SqlIdCoordinateSource import edu.ie3.datamodel.models.value.WeatherValue import edu.ie3.simona.config.SimonaConfig @@ -39,7 +39,6 @@ import edu.ie3.simona.util.ConfigUtil.DatabaseConfigUtil.{ import edu.ie3.simona.util.ParsableEnumeration import edu.ie3.util.geo.{CoordinateDistance, GeoUtils} import edu.ie3.util.quantities.PowerSystemUnits -import edu.ie3.util.scala.io.CsvDataSourceAdapter import edu.ie3.util.scala.quantities.WattsPerSquareMeter import org.locationtech.jts.geom.{Coordinate, Point} import squants.motion.MetersPerSecond @@ -470,7 +469,7 @@ object WeatherSource { () => new CsvIdCoordinateSource( idCoordinateFactory, - new CsvDataSourceAdapter( + new CsvDataSource( csvSep, Paths.get(directoryPath), new FileNamingStrategy() diff --git a/src/main/scala/edu/ie3/util/scala/io/CsvDataSourceAdapter.java b/src/main/scala/edu/ie3/util/scala/io/CsvDataSourceAdapter.java deleted file mode 100644 index 16ea4883b6..0000000000 --- a/src/main/scala/edu/ie3/util/scala/io/CsvDataSourceAdapter.java +++ /dev/null @@ -1,19 +0,0 @@ -/* - * © 2023. TU Dortmund University, - * Institute of Energy Systems, Energy Efficiency and Energy Economics, - * Research group Distribution grid planning and operation - */ - -package edu.ie3.util.scala.io; - -import edu.ie3.datamodel.io.naming.FileNamingStrategy; -import edu.ie3.datamodel.io.source.csv.CsvDataSource; -import java.nio.file.Path; - -public class CsvDataSourceAdapter extends CsvDataSource { - - public CsvDataSourceAdapter( - String csvSep, Path folderPath, FileNamingStrategy fileNamingStrategy) { - super(csvSep, folderPath, fileNamingStrategy); - } -} diff --git a/src/main/scala/edu/ie3/util/scala/io/GraphicDataCleaner.scala b/src/main/scala/edu/ie3/util/scala/io/GraphicDataCleaner.scala index 7737599d18..e4a66cbf5c 100644 --- a/src/main/scala/edu/ie3/util/scala/io/GraphicDataCleaner.scala +++ b/src/main/scala/edu/ie3/util/scala/io/GraphicDataCleaner.scala @@ -31,7 +31,7 @@ object GraphicDataCleaner { /* setup */ val dataSource: CsvDataSource = - new CsvDataSourceAdapter(csvSep, baseFolder, fileNamingStrategy) + new CsvDataSource(csvSep, baseFolder, fileNamingStrategy) val csvTypeSource: TypeSource = new TypeSource(dataSource) From 707fc989981b6f9d2bb6d7fc19fcf86710169124 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Wed, 24 Jan 2024 09:38:16 +0000 Subject: [PATCH 2/4] Bump com.diffplug.spotless from 6.24.0 to 6.25.0 (#711) --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index df74551b94..1279fd5819 100644 --- a/build.gradle +++ b/build.gradle @@ -7,7 +7,7 @@ plugins { id 'signing' id 'maven-publish' // publish to a maven repo (local or mvn central, has to be defined) id 'pmd' // code check, working on source code - id 'com.diffplug.spotless' version '6.24.0'// code format + id 'com.diffplug.spotless' version '6.25.0'// code format id "com.github.ben-manes.versions" version '0.51.0' id "de.undercouch.download" version "5.5.0" // downloads plugin id "kr.motd.sphinx" version "2.10.1" // documentation generation From 00ecca684248a5da857274a93278015d0ac87b76 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Thu, 25 Jan 2024 09:25:12 +0000 Subject: [PATCH 3/4] Bump org.mockito:mockito-core from 5.9.0 to 5.10.0 (#713) --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 1279fd5819..157c5d3dd5 100644 --- a/build.gradle +++ b/build.gradle @@ -107,7 +107,7 @@ dependencies { /* testing */ testImplementation 'org.spockframework:spock-core:2.3-groovy-4.0' testImplementation 'org.scalatestplus:mockito-3-4_2.13:3.2.10.0' - testImplementation 'org.mockito:mockito-core:5.9.0' // mocking framework + testImplementation 'org.mockito:mockito-core:5.10.0' // mocking framework testImplementation "org.scalatest:scalatest_${scalaVersion}:3.2.17" testRuntimeOnly 'com.vladsch.flexmark:flexmark-all:0.64.8' //scalatest html output testImplementation group: 'org.pegdown', name: 'pegdown', version: '1.6.0' From 82e108cfd1b171e45e6996bfaabc95b0ae93ca37 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 29 Jan 2024 09:11:21 +0000 Subject: [PATCH 4/4] Bump pekkoVersion from 1.0.1 to 1.0.2 (#716) --- build.gradle | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/build.gradle b/build.gradle index 157c5d3dd5..8790cd28bf 100644 --- a/build.gradle +++ b/build.gradle @@ -25,7 +25,7 @@ ext { scalaVersion = '2.13' scalaBinaryVersion = '2.13.12' - pekkoVersion = '1.0.1' + pekkoVersion = '1.0.2' jtsVersion = '1.19.0' confluentKafkaVersion = '7.4.0' tscfgVersion = '1.0.2'