diff --git a/src/display_controller.py b/src/display_controller.py index e69d7f0a..25106386 100644 --- a/src/display_controller.py +++ b/src/display_controller.py @@ -476,7 +476,8 @@ class DisplayController: if self.youtube: self.youtube.update() if self.text_display: self.text_display.update() if self.of_the_day: self.of_the_day.update(time.time()) - if self.news_manager: self.news_manager.fetch_news_data() + # News manager fetches data when displayed, not during updates + # if self.news_manager: self.news_manager.fetch_news_data() # Update NHL managers if self.nhl_live: self.nhl_live.update() diff --git a/src/news_manager.py b/src/news_manager.py index fe097267..31fd0b3c 100644 --- a/src/news_manager.py +++ b/src/news_manager.py @@ -430,6 +430,10 @@ class NewsManager: self.display_manager.image = img self.display_manager.update_display() + # Debug: log scroll position + if hasattr(self, 'scroll_position') and hasattr(self, 'total_scroll_width'): + logger.debug(f"Scroll position: {self.scroll_position}/{self.total_scroll_width}") + except Exception as e: logger.error(f"Error in news display: {e}") # Create error image @@ -504,10 +508,5 @@ class NewsManager: def get_dynamic_duration(self) -> int: """Get the calculated dynamic duration for display""" - # Ensure we have current data and calculated duration - if not self.cached_text or self.dynamic_duration == 60: - # Try to refresh if we don't have current data - if self.should_update() or not self.current_headlines: - self.fetch_news_data() - + # Return the current calculated duration without fetching data return self.dynamic_duration \ No newline at end of file