Skip to content

Commit

Permalink
Ensure datacovesconfigloader is a singleton
Browse files Browse the repository at this point in the history
  • Loading branch information
BAntonellini committed May 29, 2024
1 parent 12c4c2c commit de4811d
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/dbt_core_interface/sqlfluff_util.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,6 @@ def load_extra_config(self, extra_config_path: str) -> Dict[str, Any]:
f"Extra config '{extra_config_path}' does not exist."
)

# First check the cache
# if str(extra_config_path) in self._config_cache:
# return self._config_cache[str(extra_config_path)] # TODO here

configs: Dict[str, Any] = {}
if extra_config_path.endswith("pyproject.toml"):
elems = self._get_config_elems_from_toml(extra_config_path)
Expand Down Expand Up @@ -63,7 +59,7 @@ def get_config(
directory.
"""
overrides = {k: kwargs[k] for k in kwargs if kwargs[k] is not None}
loader = DatacovesConfigLoader()
loader = DatacovesConfigLoader().get_global()

# Load config at project root
base_config = loader.load_config_up_to_path(
Expand Down

0 comments on commit de4811d

Please sign in to comment.