iotaledger / iri

IOTA Reference Implementation
Other
1.15k stars 371 forks source link

Fix: Milestone solidifier log milestone on validity not solidity #1846

Closed DyrellC closed 4 years ago

DyrellC commented 4 years ago

Description of change

When making the change in 1845, the registration of milestones was placed into the addSeenMilestones method which is only called once a milestone is valid AND solid. Failing to register new milestones on validity regardless of solidity causes an error that flies under the radar with the regression test setup. We need to register and log the new milestones as they get validated, otherwise the solidification process never kicks off. This part of the logic is no different from the previous implementation with the LatestMileStoneTracker and shouldn't be changed.

Type of change

How the change has been tested

Tests all passed on the last version and didn't catch this bug. Throwing it up onto the ICC and testing it there has allowed me to catch it in the act, and determine the cause. With this one line change the ICC syncs again without issue.

Change checklist