Skip to content

Saleor Core: the high performance, composable, headless commerce API.

Add settings env. Remove plugins added for testing

Maciej Korycinski1b3719252d45
diff --git a/saleor/core/extensions/plugin.py b/saleor/core/extensions/plugin.py
index 06656448ef..ebc79486e0 100644
--- a/saleor/core/extensions/plugin.py
+++ b/saleor/core/extensions/plugin.py
@@ -82,28 +82,3 @@ class BasePlugin:
self, obj: Union["Product", "ProductType"]
) -> TaxType:
raise NotImplementedError()
-
-
-class VatlayerPlugin(BasePlugin):
- """"""
-
- taxes = None
- # SimpleLazyObject(
- # lambda: get_taxes_for_country(request.country)
- # )
-
- def apply_taxes_to_product(
- self, product: "Product", price: Money, country: Country, **kwargs
- ):
- from ..taxes.vatlayer import get_taxes_for_country
- from ..taxes.vatlayer.interface import apply_taxes_to_product
-
- if not self.taxes:
- self.taxes = get_taxes_for_country(country)
- return apply_taxes_to_product(
- product, price, country, taxes=self.taxes, **kwargs
- )
-
-
-class AvalaraPlugin(BasePlugin):
- """"""
diff --git a/saleor/settings.py b/saleor/settings.py
index 6467825fb9..46f4bf8bb5 100644
--- a/saleor/settings.py
+++ b/saleor/settings.py
@@ -659,6 +659,8 @@ GRAPHENE = {
"RELAY_CONNECTION_MAX_LIMIT": 100,
}
-EXTENSIONS_MANAGER = "saleor.core.extensions.manager.BaseManager"
+EXTENSIONS_MANAGER = os.environ.get(
+ "EXTENSIONS_MANAGER", "saleor.core.extensions.manager.BaseManager"
+)
-PLUGINS = []
+PLUGINS = os.environ.get("PLUGINS", [])