mirror of
https://github.com/turbot/steampipe.git
synced 2026-03-21 16:00:13 -04:00
* Add test demonstrating bug #4783 - updateConnectionSchema with nil pool This test verifies that updateConnectionSchema handles a nil pool gracefully. While RefreshConnections (via newRefreshConnectionState) already checks for nil pool since #4778, this test demonstrates that updateConnectionSchema should perform an early nil check for better error handling. The test currently passes because newRefreshConnectionState catches the nil pool, but we should add an explicit check at the start of updateConnectionSchema for clarity and to avoid unnecessary work. Related to issue #4783 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> * Fix #4783: Add nil pool check in updateConnectionSchema Add an early nil check for the pool at the beginning of updateConnectionSchema to prevent unnecessary work and provide clearer error handling. While newRefreshConnectionState (called by RefreshConnections) already checks for nil pool since #4778, adding the check at the start of updateConnectionSchema provides several benefits: 1. Avoids unnecessary work - we don't call RefreshConnections if pool is nil 2. Clearer error logging - warning message specifically indicates the issue is in updateConnectionSchema 3. Defense in depth - validates preconditions before executing the method The method is called from the message server when a plugin sends a schema update notification, so the nil check ensures we handle edge cases gracefully. Closes #4783 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com> --------- Co-authored-by: Claude <noreply@anthropic.com>