Skip to content

Commit

Permalink
Refact: Remove Allow_Shedding from dict repr of GridObject
Browse files Browse the repository at this point in the history
  • Loading branch information
DEUCE1957 committed Nov 4, 2024
1 parent 2907eb9 commit 204afe5
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 6 deletions.
5 changes: 0 additions & 5 deletions grid2op/Space/GridObjects.py
Original file line number Diff line number Diff line change
Expand Up @@ -3931,8 +3931,6 @@ def _make_cls_dict(cls, res, as_list=True, copy_=True, _topo_vect_only=False):
res["name_shunt"] = None
res["shunt_to_subid"] = None

# Shedding
save_to_dict(res, cls, "allow_shedding", bool, copy_)

if not _topo_vect_only:
# all the attributes bellow are not needed for the "first call"
Expand Down Expand Up @@ -4131,9 +4129,6 @@ def _make_cls_dict_extended(cls, res: CLS_AS_DICT_TYPING, as_list=True, copy_=Tr
# n_busbar_per_sub
res["n_busbar_per_sub"] = cls.n_busbar_per_sub

# Shedding
res["allow_shedding"] = cls.allow_shedding

# avoid further computation and save it
if not as_list and not _topo_vect_only:
cls._CLS_DICT_EXTENDED = res.copy()
Expand Down
1 change: 0 additions & 1 deletion grid2op/tests/test_Observation.py
Original file line number Diff line number Diff line change
Expand Up @@ -299,7 +299,6 @@ def setUp(self):
"alertable_line_ids": [],
"assistant_warning_type": None,
"_PATH_GRID_CLASSES": None,
"allow_shedding": False,
}

self.json_ref = {
Expand Down

0 comments on commit 204afe5

Please sign in to comment.