Skip to content

Commit

Permalink
Merge pull request #1064 from gridsingularity/fix_is_initial_current_…
Browse files Browse the repository at this point in the history
…market_on_cn

fix_is_initial_current_market_on_cn
  • Loading branch information
hannesdiedrich authored Feb 16, 2021
2 parents 5460f72 + bf43964 commit 3a648e7
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/d3a/d3a_core/sim_results/endpoint_buffer.py
Original file line number Diff line number Diff line change
Expand Up @@ -230,8 +230,8 @@ def update_stats(self, area, simulation_status, progress_info, sim_state):
self.area_result_dict = self._create_area_tree_dict(area)
self.status = simulation_status
is_initial_current_market_on_cn = d3a.constants.IS_CANARY_NETWORK and \
(area.next_market is None or
area.next_market.time_slot - area.current_market.time_slot > area.config.slot_length)
(area.next_market is None or (area.current_market and
area.next_market.time_slot - area.current_market.time_slot > area.config.slot_length))
if area.current_market is not None and not is_initial_current_market_on_cn:
self.current_market_time_slot_str = area.current_market.time_slot_str
self.current_market_ui_time_slot_str = \
Expand Down

0 comments on commit 3a648e7

Please sign in to comment.