Increment generation counter for an island
(self, island_idx: Optional[int] = None)
| 1771 | return self.current_island |
| 1772 | |
| 1773 | def increment_island_generation(self, island_idx: Optional[int] = None) -> None: |
| 1774 | """Increment generation counter for an island""" |
| 1775 | idx = island_idx if island_idx is not None else self.current_island |
| 1776 | self.island_generations[idx] += 1 |
| 1777 | logger.debug(f"Island {idx} generation incremented to {self.island_generations[idx]}") |
| 1778 | |
| 1779 | def should_migrate(self) -> bool: |
| 1780 | """Check if migration should occur based on generation counters""" |