Преглед на файлове

Rewrite duplicate override error message

Signed-off-by: Joffrey F <[email protected]>
Joffrey F преди 8 години
родител
ревизия
7f1f450080
променени са 1 файла, в които са добавени 4 реда и са изтрити 7 реда
  1. 4 7
      compose/config/errors.py

+ 4 - 7
compose/config/errors.py

@@ -49,10 +49,7 @@ class ComposeFileNotFound(ConfigurationError):
 class DuplicateOverrideFileFound(ConfigurationError):
     def __init__(self, override_filenames):
         self.override_filenames = override_filenames
-
-    @property
-    def msg(self):
-        return """
-        Unable to determine with duplicate override files, only a single override file can be used.
-        Found: %s
-        """ % ", ".join(self.override_filenames)
+        super(DuplicateOverrideFileFound, self).__init__(
+            "Multiple override files found: {}. You may only use a single "
+            "override file.".format(", ".join(override_filenames))
+        )