Code Duplication    Length = 12-13 lines in 2 locations

src/egon/data/datasets/power_plants/__init__.py 1 location

@@ 37-49 (lines=13) @@
34
Base = declarative_base()
35
36
37
class EgonPowerPlants(Base):
38
    __tablename__ = "egon_power_plants"
39
    __table_args__ = {"schema": "supply"}
40
    id = Column(BigInteger, Sequence("pp_seq"), primary_key=True)
41
    sources = Column(JSONB)
42
    source_id = Column(JSONB)
43
    carrier = Column(String)
44
    el_capacity = Column(Float)
45
    bus_id = Column(Integer)
46
    voltage_level = Column(Integer)
47
    weather_cell_id = Column(Integer)
48
    scenario = Column(String)
49
    geom = Column(Geometry("POINT", 4326))
50
51
52
class PowerPlants(Dataset):

src/egon/data/datasets/storages/__init__.py 1 location

@@ 26-37 (lines=12) @@
23
Base = declarative_base()
24
25
26
class EgonStorages(Base):
27
    __tablename__ = "egon_storages"
28
    __table_args__ = {"schema": "supply"}
29
    id = Column(BigInteger, Sequence("storage_seq"), primary_key=True)
30
    sources = Column(JSONB)
31
    source_id = Column(JSONB)
32
    carrier = Column(String)
33
    el_capacity = Column(Float)
34
    bus_id = Column(Integer)
35
    voltage_level = Column(Integer)
36
    scenario = Column(String)
37
    geom = Column(Geometry("POINT", 4326))
38
39
40
class PumpedHydro(Dataset):