Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 9 additions & 6 deletions docs/uml.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@
`compile_files_kroki(...)`.
It is designed to work together with `pydantic` and only is tested in this project so far.
"""

import importlib
import inspect
import json
Expand Down Expand Up @@ -113,12 +114,14 @@ def add_class(self, node: str, cls: type[BaseModel]) -> None:
super().add_node(
node,
cls=cls,
fields={
field_name: {"model_field": model_field, "card": None}
for field_name, model_field in cls.model_fields.items()
}
if hasattr(cls, "model_fields")
else {},
fields=(
{
field_name: {"model_field": model_field, "card": None}
for field_name, model_field in cls.model_fields.items()
}
if hasattr(cls, "model_fields")
else {}
),
)

def add_extension(self, node1: str, node2: str) -> None:
Expand Down
1 change: 1 addition & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ sources = ["src"]

[tool.black]
line-length = 120
target_version = ["py38", "py39", "py310", "py311", "py312"]

[tool.setuptools_scm]

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@

The BO4E version can be queried using `bo4e.__version__`.
"""

__all__ = [
"Angebot",
"Ausschreibung",
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/ausschreibung.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Ausschreibung class and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime

# pylint: disable=too-few-public-methods, too-many-instance-attributes
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/energiemenge.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Energiemenge class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/fremdkosten.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Fremdkosten class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/geraet.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Geraet class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/kosten.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Kosten class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/lastgang.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Lastgang class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

# pylint: disable=too-few-public-methods
Expand Down
1 change: 0 additions & 1 deletion src/bo4e/bo/marktteilnehmer.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
and corresponding marshmallow schema for de-/serialization
"""


# pylint: disable=too-few-public-methods
# pylint: disable=no-name-in-module
from typing import Annotated, Optional
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/messlokation.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Messlokation class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/preisblattdienstleistung.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PreisblattDienstleistung class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/preisblatthardware.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PreisblattHardware class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/preisblattkonzessionsabgabe.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PreisblattKonzessionsabgabe class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/preisblattmessung.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PreisblattMessung class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/preisblattnetznutzung.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PreisblattNetnutzung class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/region.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Region class and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/tarifkosten.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Tarifkosten class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Annotated, Optional

from pydantic import Field
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/tarifpreisblatt.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Tarifpreisblatt class and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime
from typing import Annotated, Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/vertrag.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Vertrag class
and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime
from typing import Annotated, Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/bo/zaehler.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Zaehler class
and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime
from decimal import Decimal

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/adresse.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Adresse class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.landescode import Landescode
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/angebotsposition.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Angebotsposition class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/angebotsteil.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Angebotsteil class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..bo.marktlokation import Marktlokation
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/angebotsvariante.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Angebotsvariante and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime

# pylint: disable=too-few-public-methods
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/aufabschlagproort.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains AufAbschlagProOrt class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/ausschreibungsdetail.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains class Ausschreibungsdetail and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.zaehlertyp import Zaehlertyp
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/dienstleistung.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Dienstleistung class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.dienstleistungstyp import Dienstleistungstyp
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/energieherkunft.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Energieherkunft class
and corresponding marshmallow schema for de-/serialization
"""

from decimal import Decimal
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/fremdkostenposition.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Fremdkostenposition and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/geokoordinaten.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Geokoordinaten class
and corresponding marshmallow schema for de-/serialization
"""

from decimal import Decimal
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/katasteradresse.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Katasteradresse class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/konzessionsabgabe.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Konzessionsabgabe and corresponding marshmallow schema for de-/serialization
"""

from decimal import Decimal
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/kostenblock.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Kostenblock and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/kostenposition.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Kostenposition and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/kriteriumwert.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains KriteriumWert class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

# pylint: disable=too-few-public-methods
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/marktgebietinfo.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Marktgebietinfo class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/messlokationszuordnung.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Messlokationszuordnung class
and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/positionsaufabschlag.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains PositionsAufAbschlag and corresponding marshmallow schema for de-/serialization
"""

from decimal import Decimal
from typing import Optional

Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/preisgarantie.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains Preisgarantie class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.preisgarantietyp import Preisgarantietyp
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/preisposition.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Preisposition class and corresponding marshmallow schema for de-/serialization
"""

from decimal import Decimal

# pylint: disable=no-name-in-module
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/rechnungsposition.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Rechnungsposition class and corresponding marshmallow schema for de-/serialization
"""

from datetime import datetime

# pylint: disable=too-few-public-methods, too-many-instance-attributes
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/regionalegueltigkeit.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains RegionaleGueltigkeit class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.gueltigkeitstyp import Gueltigkeitstyp
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/regionalepreisgarantie.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains RegionalePreisgarantie class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/regionalepreisstaffel.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains RegionalePreisstaffel class and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/regionskriterium.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
"""
Contains Regionskriterium class and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..enum.gueltigkeitstyp import Gueltigkeitstyp
Expand Down
1 change: 1 addition & 0 deletions src/bo4e/com/standorteigenschaftengas.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
Contains StandorteigenschaftenGas class
and corresponding marshmallow schema for de-/serialization
"""

from typing import Optional

from ..utils import postprocess_docstring
Expand Down
Loading