Skip to content

Commit

Permalink
Set state for all parameters to fix bug
Browse files Browse the repository at this point in the history
  • Loading branch information
hdoupe committed Jan 4, 2021
1 parent 4582583 commit f75d6b7
Showing 1 changed file with 1 addition and 4 deletions.
5 changes: 1 addition & 4 deletions taxcalc/parameters.py
Original file line number Diff line number Diff line change
Expand Up @@ -424,6 +424,7 @@ def adjust_with_indexing(self, params_or_path, **kwargs):
# Re-instate ops.
self.label_to_extend = label_to_extend
self.array_first = array_first
self.set_state()

# Filter out "-indexed" params.
nonindexed_params = {
Expand All @@ -432,10 +433,6 @@ def adjust_with_indexing(self, params_or_path, **kwargs):
if param not in index_affected
}

needs_reset = set(needs_reset) - set(nonindexed_params.keys())
if needs_reset:
self._set_state(params=needs_reset)

# 3. Do adjustment for all non-indexing related parameters.
adj = super().adjust(nonindexed_params, **kwargs)

Expand Down

0 comments on commit f75d6b7

Please sign in to comment.