Skip to content

Commit

Permalink
fix: bypass database connection whenever connected to local
Browse files Browse the repository at this point in the history
  • Loading branch information
fubuloubu committed Aug 18, 2022
1 parent 44aac00 commit 6c79a10
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/ape_cache/query.py
Original file line number Diff line number Diff line change
Expand Up @@ -116,6 +116,8 @@ def database_connection(self):
Returns:
Optional[`sqlalchemy.engine.Connection`]
"""
if self.provider.network.name == LOCAL_NETWORK_NAME:
return None

if not self.network_manager.active_provider:
raise QueryEngineError("Not connected to a provider")
Expand Down

0 comments on commit 6c79a10

Please sign in to comment.