diff --git a/src/ralph/assets/api/views.py b/src/ralph/assets/api/views.py index cd90d49a5b..4aa0ac92d4 100644 --- a/src/ralph/assets/api/views.py +++ b/src/ralph/assets/api/views.py @@ -11,7 +11,7 @@ from ralph.assets.api import serializers from ralph.assets.api.filters import NetworkableObjectFilters from ralph.assets.models import BaseObject -from ralph.data_center.models import Cluster, DataCenterAsset, DCHost +from ralph.data_center.models import Cluster, DataCenterAsset from ralph.lib.api.utils import renderer_classes_without_form from ralph.licences.api import BaseObjectLicenceViewSet from ralph.licences.models import BaseObjectLicence @@ -317,7 +317,7 @@ def get_serializer_class(self, *args, **kwargs): elif isinstance(obj_, Cluster): from ralph.data_center.api.serializers import ClusterSerializer return ClusterSerializer - except AssertionError: # for some reason when opening browsable api this raises exception + except AssertionError: # for some reason when opening browsable api this raises pass return serializers.DCHostSerializer