Skip to content

Commit 6245aec

Browse files
committed
Merge branch 'dev' into vb/#791_delete_initFiles
# Conflicts: # CHANGELOG.md
2 parents 78ca290 + 447e13d commit 6245aec

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

41 files changed

+1735
-722
lines changed

.readthedocs.yaml

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,9 +7,9 @@ version: 2
77

88
# Set the version of Python and other tools you might need
99
build:
10-
os: ubuntu-20.04
10+
os: ubuntu-22.04
1111
tools:
12-
python: "3.9"
12+
python: "3.11"
1313

1414
# Configure python
1515
python:
@@ -18,4 +18,5 @@ python:
1818

1919
# Build documentation in the docs/ directory with Sphinx
2020
sphinx:
21-
configuration: docs/readthedocs/conf.py
21+
configuration: docs/readthedocs/conf.py
22+
fail_on_warning: true

CHANGELOG.md

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,8 +8,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
88

99
### Added
1010
- Copy methods for container classes [#726](https://github.com/ie3-institute/PowerSystemDataModel/issues/726)
11+
- Allow hierarchic grid structure for JointGridContainer [#768](https://github.com/ie3-institute/PowerSystemDataModel/issues/768)
12+
- Adding SQL id coordinate sources (``IdCoordinateSource``) [#689](https://github.com/ie3-institute/PowerSystemDataModel/issues/689)
1113

1214
### Fixed
15+
- Fixed wrong rated power unit hint [#804](https://github.com/ie3-institute/PowerSystemDataModel/issues/804)
16+
- Fixed wrong hash code generation of ConnectorResult [#817](https://github.com/ie3-institute/PowerSystemDataModel/issues/817)
1317

1418

1519
### Changed

build.gradle

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ plugins {
44
id 'maven-publish'
55
id 'signing'
66
id 'pmd' // code check, working on source code
7-
id 'com.diffplug.spotless' version '6.18.0'//code format
7+
id 'com.diffplug.spotless' version '6.19.0'//code format
88
id 'com.github.spotbugs' version '5.0.14' // code check, working on byte code
99
id 'de.undercouch.download' version '5.4.0'
1010
id 'kr.motd.sphinx' version '2.10.1' // documentation generation
@@ -17,8 +17,8 @@ ext {
1717
//version (changing these should be considered thoroughly!)
1818
javaVersion = JavaVersion.VERSION_17
1919
groovyVersion = "4.0"
20-
groovyBinaryVersion = "4.0.11"
21-
testcontainersVersion = '1.18.0'
20+
groovyBinaryVersion = "4.0.12"
21+
testcontainersVersion = '1.18.1'
2222

2323
scriptsLocation = 'gradle' + File.separator + 'scripts' + File.separator //location of script plugins
2424
}
@@ -62,12 +62,12 @@ dependencies {
6262
implementation 'org.locationtech.jts.io:jts-io-common:1.19.0'
6363

6464
// Graphs
65-
implementation 'org.jgrapht:jgrapht-core:1.5.1'
65+
implementation 'org.jgrapht:jgrapht-core:1.5.2'
6666

6767
// testing
6868
testImplementation "org.apache.groovy:groovy:$groovyBinaryVersion"
6969

70-
testImplementation 'org.junit.jupiter:junit-jupiter:5.9.2'
70+
testImplementation 'org.junit.jupiter:junit-jupiter:5.9.3'
7171
testImplementation "org.spockframework:spock-core:2.3-groovy-$groovyVersion"
7272
testImplementation 'org.objenesis:objenesis:3.3' // Mock creation with constructor parameters
7373
testImplementation 'net.bytebuddy:byte-buddy:1.14.4' // Mocks of classes
@@ -87,10 +87,10 @@ dependencies {
8787

8888
// Databases
8989
implementation 'org.influxdb:influxdb-java:2.23'
90-
implementation 'com.couchbase.client:java-client:3.4.5'
90+
implementation 'com.couchbase.client:java-client:3.4.6'
9191
runtimeOnly 'org.postgresql:postgresql:42.6.0' // postgresql jdbc driver required during runtime
9292

93-
implementation 'commons-io:commons-io:2.11.0' // I/O functionalities
93+
implementation 'commons-io:commons-io:2.12.0' // I/O functionalities
9494
implementation 'org.apache.commons:commons-compress:1.23.0' // I/O functionalities
9595
implementation 'org.apache.commons:commons-lang3:3.12.0'
9696
}

docs/readthedocs/conf.py

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -18,12 +18,12 @@
1818
# -- Project information -----------------------------------------------------
1919

2020
project = 'PowerSystemDataModel'
21-
copyright = u'2020. TU Dortmund University, Institute of Energy Systems, Energy Efficiency and Energy Economics, Research group Distribution grid planning and operation '
22-
author = 'Johannes Hiry, Debopama Sen Sarma, Chris Kittl'
21+
copyright = u'2023. TU Dortmund University, Institute of Energy Systems, Energy Efficiency and Energy Economics, Research group Distribution grid planning and operation '
22+
author = 'Institute of Energy Systems, Energy Efficiency and Energy Economics'
2323

2424
# The full version, including alpha/beta/rc tags
25-
version = '1.0'
26-
release = '1.0.1-SNAPSHOT'
25+
version = '3.0'
26+
release = '3.0.0'
2727

2828
pygments_style = 'tango'
2929
add_function_parentheses = True
@@ -35,12 +35,12 @@
3535
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
3636
# ones.
3737
extensions = [
38-
'recommonmark',
39-
'sphinx.ext.autosectionlabel'
38+
'sphinx.ext.intersphinx',
39+
'myst_parser'
4040
]
4141

42-
# Prefix all autogenerated labels wit the document to get unique labels (e.g. `index:Hello`)
43-
autosectionlabel_prefix_document = True
42+
myst_enable_extensions = ["dollarmath", "amsmath"]
43+
myst_heading_anchors = 4
4444

4545
# Add any paths that contain templates here, relative to this directory.
4646
templates_path = ['_templates']
@@ -49,7 +49,8 @@
4949
# directories to ignore when looking for source files.
5050
# This pattern also affects html_static_path and html_extra_path.
5151
exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store', 'venv']
52-
52+
exclude_trees = ['.build']
53+
source_suffix = ['.rst', '.md']
5354
source_encoding = 'utf-8-sig'
5455

5556
# -- Options for HTML output -------------------------------------------------

docs/readthedocs/models/ValidationUtils.rst renamed to docs/readthedocs/io/ValidationUtils.md

Lines changed: 13 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,26 @@
1-
****************
2-
Validation Utils
3-
****************
1+
# Validation Utils
42
This page gives an overview about the ValidationUtils in the *PowerSystemDataModel*.
53

6-
What are the ValidationUtils?
7-
=============================
4+
## What are the ValidationUtils?
85
The methods in ValidationUtils and subclasses can be used to check that objects are valid, meaning their parameters have valid values and they are correctly connected.
96

10-
What is checked?
11-
================
7+
## What is checked?
128
- The check methods include checks that assigned values are valid, e.g. lines are not allowed to have negative lengths or the rated power factor of any unit must be between 0 and 1.
139
- Furthermore, several connections are checked, e.g. that lines only connect nodes of the same voltage level or that the voltage levels indicated for the transformer sides match the voltage levels of the nodes they are connected to.
1410

15-
How does it work?
16-
=================
17-
- The method :code:`ValidationUtils.check(Object)` is the only method that should be called by the user.
11+
## How does it work?
12+
- The method `ValidationUtils.check(Object)` is the only method that should be called by the user.
1813
- This check method identifies the object class and forwards it to a specific check method for the given object
1914
- The overall structure of the ValidationUtils methods follows a cascading scheme, orientated along the class tree
20-
- Example: A :code:`LineInput lineInput` should be checked
21-
1. :code:`ValidationUtils.check(lineInput)` is called
22-
2. :code:`ValidationUtils.check(lineInput)` identifies the class of the object as :code:`AssetInput` and calls :code:`ValidationUtils.checkAsset(lineInput)`
23-
3. :code:`ValidationUtils.checkAsset(lineInput)`, if applicable, checks those parameters that all :code:`AssetInput` have in common (e.g. operation time) and further identifies the object, more specifically, as a :code:`ConnectorInput` and calls :code:`ConnectorValidationUtils.check(lineInput)`
24-
4. :code:`ConnectorValidationUtils.check(lineInput)`, if applicable, checks those parameters that all :code:`ConnectorInput` have in common and further identifies the object, more specifically, as a :code:`LineInput` and calls :code:`ConnectorValidationUtils.checkLine(lineInput)`
25-
5. :code:`ConnectorValidationUtils.checkLine(lineInput)` checks all specific parameters of a :code:`LineInput`
15+
- Example: A `LineInput lineInput` should be checked
16+
1. `ValidationUtils.check(lineInput)` is called
17+
2. `ValidationUtils.check(lineInput)` identifies the class of the object as `AssetInput` and calls `ValidationUtils.checkAsset(lineInput)`
18+
3. `ValidationUtils.checkAsset(lineInput)`, if applicable, checks those parameters that all `AssetInput` have in common (e.g. operation time) and further identifies the object, more specifically, as a `ConnectorInput` and calls `ConnectorValidationUtils.check(lineInput)`
19+
4. `ConnectorValidationUtils.check(lineInput)`, if applicable, checks those parameters that all `ConnectorInput` have in common and further identifies the object, more specifically, as a `LineInput` and calls `ConnectorValidationUtils.checkLine(lineInput)`
20+
5. `ConnectorValidationUtils.checkLine(lineInput)` checks all specific parameters of a `LineInput`
2621
- ValidationUtils furthermore contains several utils methods used in the subclasses
2722

28-
Which objects are checked?
29-
==========================
23+
## Which objects are checked?
3024
The ValidationUtils include validation checks for...
3125

3226
- NodeValidationUtils
@@ -80,8 +74,7 @@ The ValidationUtils include validation checks for...
8074
- RawGridElements
8175
- SystemParticipants
8276

83-
What should be considered?
84-
==========================
77+
## What should be considered?
8578
- Due to many checks with if-conditions, the usage of the ValidationUtils for many objects might be runtime relevant.
8679
- The check for a GridContainer includes the interplay of the contained entities as well as the checks of all contained entities.
8780
- If new classes are introduced to the *PowerSystemDataModel*, make sure to follow the forwarding structure of the ValidationUtils methods when writing the check methods!

docs/readthedocs/io/basiciousage.rst

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -8,9 +8,10 @@ Therefore, the I/O-package is structured as highly modular.
88
.. toctree::
99
:maxdepth: 2
1010

11-
influxdb
1211
csvfiles
13-
12+
sql
13+
influxdb
14+
ValidationUtils.md
1415

1516

1617
Data sink structure

0 commit comments

Comments
 (0)