We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
is_displayed for catalog all page is not working as expected
Currently the is_display of catalog all page returns True even if the view is on Add catalog page.

--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `cfme/services/catalogs/catalog.py`
Content:
```
1 import attr
2 from navmazing import NavigateToAttribute
3 from navmazing import NavigateToSibling
4 from widgetastic.utils import Parameter
5 from widgetastic.widget import Text
6 from widgetastic_patternfly import Button
7 from widgetastic_patternfly import CandidateNotFound
8 from widgetastic_patternfly import Input
9 
10 from . import ServicesCatalogView
11 from cfme.common import Taggable
12 from cfme.modeling.base import BaseCollection
13 from cfme.modeling.base import BaseEntity
14 from cfme.utils.appliance.implementations.ui import CFMENavigateStep
15 from cfme.utils.appliance.implementations.ui import navigate_to
16 from cfme.utils.appliance.implementations.ui import navigator
17 from cfme.utils.pretty import Pretty
18 from cfme.utils.update import Updateable
19 from cfme.utils.wait import wait_for
20 from widgetastic_manageiq import MultiBoxSelect
21 
22 
23 class CatalogsMultiBoxSelect(MultiBoxSelect):
24     move_into_button = Button(title=Parameter("@move_into"))
25     move_from_button = Button(title=Parameter("@move_from"))
26 
27 
28 class CatalogForm(ServicesCatalogView):
29     title = Text('#explorer_title_text')
30 
31     name = Input(name='name')
32     description = Input(name="description")
33     assign_catalog_items = CatalogsMultiBoxSelect(
34         move_into="Move Selected buttons right",
35         move_from="Move Selected buttons left",
36         available_items="available_fields",
37         chosen_items="selected_fields"
38     )
39 
40     save_button = Button('Save')
41     cancel_button = Button('Cancel')
42 
43 
44 class CatalogsView(ServicesCatalogView):
45     title = Text("#explorer_title_text")
46 
47     @property
48     def is_displayed(self):
49         return (
50             self.in_explorer and
51             self.catalogs.is_opened and
52             self.catalogs.tree.currently_selected == ["All Catalogs"])
53 
54 
55 class DetailsCatalogView(ServicesCatalogView):
56     title = Text("#explorer_title_text")
57 
58     @property
59     def is_displayed(self):
60         return (
61             self.in_explorer and self.catalogs.is_opened and
62             self.title.text == 'Catalog "{}"'.format(self.context["object"].name)
63         )
64 
65 
66 class AddCatalogView(CatalogForm):
67 
68     add_button = Button("Add")
69 
70     @property
71     def is_displayed(self):
72         return (
73             self.in_explorer and self.catalogs.is_opened and
74             self.title.text == 'Adding a new Catalog'
75         )
76 
77 
78 class EditCatalogView(CatalogForm):
79 
80     save_button = Button('Save')
81     reset_button = Button('Reset')
82 
83     @property
84     def is_displayed(self):
85         return (
86             self.in_explorer and self.catalogs.is_opened and
87             self.title.text == 'Editing Catalog "{}"'.format(self.context["object"].name)
88         )
89 
90 
91 @attr.s
92 class Catalog(BaseEntity, Updateable, Pretty, Taggable):
93 
94     name = attr.ib()
95     description = attr.ib()
96     items = attr.ib(default=None)
97 
98     def update(self, updates):
99         view = navigate_to(self, 'Edit')
100         changed = view.fill(updates)
101         if changed:
102             view.save_button.click()
103         else:
104             view.cancel_button.click()
105         view = self.create_view(DetailsCatalogView, override=updates, wait='10s')
106         view.flash.assert_no_error()
107         if changed:
108             view.flash.assert_message(
109                 'Catalog "{}" was saved'.format(updates.get('name', self.name)))
110         else:
111             view.flash.assert_message(
112                 'Edit of Catalog "{}" was cancelled by the user'.format(self.name))
113 
114     def delete(self):
115         view = navigate_to(self, "Details")
116         view.configuration.item_select('Remove Catalog', handle_alert=True)
117         view = self.create_view(CatalogsView, wait='10s')
118         view.flash.assert_no_error()
119         view.flash.assert_success_message(
120             'Catalog "{}": Delete successful'.format(self.description or self.name))
121 
122     @property
123     def exists(self):
124         try:
125             navigate_to(self, 'Details')
126             return True
127         except (NameError, CandidateNotFound):
128             return False
129 
130 
131 @attr.s
132 class CatalogCollection(BaseCollection):
133     """A collection for the :py:class:`cfme.services.catalogs.catalog.Catalog`"""
134     ENTITY = Catalog
135 
136     def create(self, name, description, items=None):
137         """Create a catalog.
138 
139         Args:
140             name: The name of the catalog
141             description: The description of the catalog
142             items: Items in the catalog
143         """
144         view = navigate_to(self, 'Add')
145         view.fill({
146             'name': name,
147             'description': description,
148             'assign_catalog_items': items
149         })
150         view.add_button.click()
151         catalog = self.instantiate(name=name, description=description, items=items)
152         view = self.create_view(CatalogsView)
153         assert view.is_displayed
154         view.flash.assert_no_error()
155         return catalog
156 
157 
158 @navigator.register(CatalogCollection)
159 class All(CFMENavigateStep):
160     VIEW = CatalogsView
161     prerequisite = NavigateToAttribute('appliance.server', 'LoggedIn')
162 
163     def step(self, *args, **kwargs):
164         self.prerequisite_view.navigation.select('Services', 'Catalogs')
165         self.view.catalogs.tree.click_path("All Catalogs")
166 
167 
168 @navigator.register(CatalogCollection)
169 class Add(CFMENavigateStep):
170     VIEW = AddCatalogView
171     prerequisite = NavigateToSibling('All')
172 
173     def step(self, *args, **kwargs):
174         self.prerequisite_view.configuration.item_select('Add a New Catalog')
175 
176 
177 @navigator.register(Catalog)
178 class Details(CFMENavigateStep):
179     VIEW = DetailsCatalogView
180     prerequisite = NavigateToAttribute('parent', 'All')
181 
182     def step(self, *args, **kwargs):
183         self.prerequisite_view.catalogs.tree.click_path("All Catalogs", self.obj.name)
184 
185 
186 @navigator.register(Catalog)
187 class Edit(CFMENavigateStep):
188     VIEW = EditCatalogView
189     prerequisite = NavigateToSibling('Details')
190 
191     def step(self, *args, **kwargs):
192         self.prerequisite_view.configuration.item_select('Edit this Item')
193
```
--- END FILES ---

Please first localize the bug based on the issue statement, and then generate a patch according to the `git diff` format fenced by three backticks.

Here is an example:

```diff
diff --git a/examples/server_async.py b/examples/server_async.py
--- a/examples/server_async.py
+++ b/examples/server_async.py
@@ -313,4 +313,4 @@
 
 
 if __name__ == "__main__":
-    asyncio.run(run_async_server("."), debug=True)
+    asyncio.run(run_async_server(), debug=True)
diff --git a/examples/server_sync.py b/examples/server_sync.py
--- a/examples/server_sync.py
+++ b/examples/server_sync.py
@@ -313,5 +313,5 @@
 
 
 if __name__ == "__main__":
-    server = run_sync_server(".")
+    server = run_sync_server()
     server.shutdown()

```

diff --git a/cfme/services/catalogs/catalog.py b/cfme/services/catalogs/catalog.py
--- a/cfme/services/catalogs/catalog.py
+++ b/cfme/services/catalogs/catalog.py
@@ -49,6 +49,7 @@
         return (
             self.in_explorer and
             self.catalogs.is_opened and
+            self.title.text == "All Catalogs" and
             self.catalogs.tree.currently_selected == ["All Catalogs"])

{"golden_diff": "diff --git a/cfme/services/catalogs/catalog.py b/cfme/services/catalogs/catalog.py\n--- a/cfme/services/catalogs/catalog.py\n+++ b/cfme/services/catalogs/catalog.py\n@@ -49,6 +49,7 @@\n         return (\n             self.in_explorer and\n             self.catalogs.is_opened and\n+            self.title.text == \"All Catalogs\" and\n             self.catalogs.tree.currently_selected == [\"All Catalogs\"])\n", "issue": "is_displayed for catalog all page is not working as expected\nCurrently the is_display of catalog all page returns True even if the view is on Add catalog page.\n", "before_files": [{"content": "import attr\nfrom navmazing import NavigateToAttribute\nfrom navmazing import NavigateToSibling\nfrom widgetastic.utils import Parameter\nfrom widgetastic.widget import Text\nfrom widgetastic_patternfly import Button\nfrom widgetastic_patternfly import CandidateNotFound\nfrom widgetastic_patternfly import Input\n\nfrom . import ServicesCatalogView\nfrom cfme.common import Taggable\nfrom cfme.modeling.base import BaseCollection\nfrom cfme.modeling.base import BaseEntity\nfrom cfme.utils.appliance.implementations.ui import CFMENavigateStep\nfrom cfme.utils.appliance.implementations.ui import navigate_to\nfrom cfme.utils.appliance.implementations.ui import navigator\nfrom cfme.utils.pretty import Pretty\nfrom cfme.utils.update import Updateable\nfrom cfme.utils.wait import wait_for\nfrom widgetastic_manageiq import MultiBoxSelect\n\n\nclass CatalogsMultiBoxSelect(MultiBoxSelect):\n    move_into_button = Button(title=Parameter(\"@move_into\"))\n    move_from_button = Button(title=Parameter(\"@move_from\"))\n\n\nclass CatalogForm(ServicesCatalogView):\n    title = Text('#explorer_title_text')\n\n    name = Input(name='name')\n    description = Input(name=\"description\")\n    assign_catalog_items = CatalogsMultiBoxSelect(\n        move_into=\"Move Selected buttons right\",\n        move_from=\"Move Selected buttons left\",\n        available_items=\"available_fields\",\n        chosen_items=\"selected_fields\"\n    )\n\n    save_button = Button('Save')\n    cancel_button = Button('Cancel')\n\n\nclass CatalogsView(ServicesCatalogView):\n    title = Text(\"#explorer_title_text\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and\n            self.catalogs.is_opened and\n            self.catalogs.tree.currently_selected == [\"All Catalogs\"])\n\n\nclass DetailsCatalogView(ServicesCatalogView):\n    title = Text(\"#explorer_title_text\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Catalog \"{}\"'.format(self.context[\"object\"].name)\n        )\n\n\nclass AddCatalogView(CatalogForm):\n\n    add_button = Button(\"Add\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Adding a new Catalog'\n        )\n\n\nclass EditCatalogView(CatalogForm):\n\n    save_button = Button('Save')\n    reset_button = Button('Reset')\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Editing Catalog \"{}\"'.format(self.context[\"object\"].name)\n        )\n\n\n@attr.s\nclass Catalog(BaseEntity, Updateable, Pretty, Taggable):\n\n    name = attr.ib()\n    description = attr.ib()\n    items = attr.ib(default=None)\n\n    def update(self, updates):\n        view = navigate_to(self, 'Edit')\n        changed = view.fill(updates)\n        if changed:\n            view.save_button.click()\n        else:\n            view.cancel_button.click()\n        view = self.create_view(DetailsCatalogView, override=updates, wait='10s')\n        view.flash.assert_no_error()\n        if changed:\n            view.flash.assert_message(\n                'Catalog \"{}\" was saved'.format(updates.get('name', self.name)))\n        else:\n            view.flash.assert_message(\n                'Edit of Catalog \"{}\" was cancelled by the user'.format(self.name))\n\n    def delete(self):\n        view = navigate_to(self, \"Details\")\n        view.configuration.item_select('Remove Catalog', handle_alert=True)\n        view = self.create_view(CatalogsView, wait='10s')\n        view.flash.assert_no_error()\n        view.flash.assert_success_message(\n            'Catalog \"{}\": Delete successful'.format(self.description or self.name))\n\n    @property\n    def exists(self):\n        try:\n            navigate_to(self, 'Details')\n            return True\n        except (NameError, CandidateNotFound):\n            return False\n\n\n@attr.s\nclass CatalogCollection(BaseCollection):\n    \"\"\"A collection for the :py:class:`cfme.services.catalogs.catalog.Catalog`\"\"\"\n    ENTITY = Catalog\n\n    def create(self, name, description, items=None):\n        \"\"\"Create a catalog.\n\n        Args:\n            name: The name of the catalog\n            description: The description of the catalog\n            items: Items in the catalog\n        \"\"\"\n        view = navigate_to(self, 'Add')\n        view.fill({\n            'name': name,\n            'description': description,\n            'assign_catalog_items': items\n        })\n        view.add_button.click()\n        catalog = self.instantiate(name=name, description=description, items=items)\n        view = self.create_view(CatalogsView)\n        assert view.is_displayed\n        view.flash.assert_no_error()\n        return catalog\n\n\n@navigator.register(CatalogCollection)\nclass All(CFMENavigateStep):\n    VIEW = CatalogsView\n    prerequisite = NavigateToAttribute('appliance.server', 'LoggedIn')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.navigation.select('Services', 'Catalogs')\n        self.view.catalogs.tree.click_path(\"All Catalogs\")\n\n\n@navigator.register(CatalogCollection)\nclass Add(CFMENavigateStep):\n    VIEW = AddCatalogView\n    prerequisite = NavigateToSibling('All')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.configuration.item_select('Add a New Catalog')\n\n\n@navigator.register(Catalog)\nclass Details(CFMENavigateStep):\n    VIEW = DetailsCatalogView\n    prerequisite = NavigateToAttribute('parent', 'All')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.catalogs.tree.click_path(\"All Catalogs\", self.obj.name)\n\n\n@navigator.register(Catalog)\nclass Edit(CFMENavigateStep):\n    VIEW = EditCatalogView\n    prerequisite = NavigateToSibling('Details')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.configuration.item_select('Edit this Item')\n", "path": "cfme/services/catalogs/catalog.py"}], "after_files": [{"content": "import attr\nfrom navmazing import NavigateToAttribute\nfrom navmazing import NavigateToSibling\nfrom widgetastic.utils import Parameter\nfrom widgetastic.widget import Text\nfrom widgetastic_patternfly import Button\nfrom widgetastic_patternfly import CandidateNotFound\nfrom widgetastic_patternfly import Input\n\nfrom . import ServicesCatalogView\nfrom cfme.common import Taggable\nfrom cfme.modeling.base import BaseCollection\nfrom cfme.modeling.base import BaseEntity\nfrom cfme.utils.appliance.implementations.ui import CFMENavigateStep\nfrom cfme.utils.appliance.implementations.ui import navigate_to\nfrom cfme.utils.appliance.implementations.ui import navigator\nfrom cfme.utils.pretty import Pretty\nfrom cfme.utils.update import Updateable\nfrom cfme.utils.wait import wait_for\nfrom widgetastic_manageiq import MultiBoxSelect\n\n\nclass CatalogsMultiBoxSelect(MultiBoxSelect):\n    move_into_button = Button(title=Parameter(\"@move_into\"))\n    move_from_button = Button(title=Parameter(\"@move_from\"))\n\n\nclass CatalogForm(ServicesCatalogView):\n    title = Text('#explorer_title_text')\n\n    name = Input(name='name')\n    description = Input(name=\"description\")\n    assign_catalog_items = CatalogsMultiBoxSelect(\n        move_into=\"Move Selected buttons right\",\n        move_from=\"Move Selected buttons left\",\n        available_items=\"available_fields\",\n        chosen_items=\"selected_fields\"\n    )\n\n    save_button = Button('Save')\n    cancel_button = Button('Cancel')\n\n\nclass CatalogsView(ServicesCatalogView):\n    title = Text(\"#explorer_title_text\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and\n            self.catalogs.is_opened and\n            self.title.text == \"All Catalogs\" and\n            self.catalogs.tree.currently_selected == [\"All Catalogs\"])\n\n\nclass DetailsCatalogView(ServicesCatalogView):\n    title = Text(\"#explorer_title_text\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Catalog \"{}\"'.format(self.context[\"object\"].name)\n        )\n\n\nclass AddCatalogView(CatalogForm):\n\n    add_button = Button(\"Add\")\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Adding a new Catalog'\n        )\n\n\nclass EditCatalogView(CatalogForm):\n\n    save_button = Button('Save')\n    reset_button = Button('Reset')\n\n    @property\n    def is_displayed(self):\n        return (\n            self.in_explorer and self.catalogs.is_opened and\n            self.title.text == 'Editing Catalog \"{}\"'.format(self.context[\"object\"].name)\n        )\n\n\n@attr.s\nclass Catalog(BaseEntity, Updateable, Pretty, Taggable):\n\n    name = attr.ib()\n    description = attr.ib()\n    items = attr.ib(default=None)\n\n    def update(self, updates):\n        view = navigate_to(self, 'Edit')\n        changed = view.fill(updates)\n        if changed:\n            view.save_button.click()\n        else:\n            view.cancel_button.click()\n        view = self.create_view(DetailsCatalogView, override=updates, wait='10s')\n        view.flash.assert_no_error()\n        if changed:\n            view.flash.assert_message(\n                'Catalog \"{}\" was saved'.format(updates.get('name', self.name)))\n        else:\n            view.flash.assert_message(\n                'Edit of Catalog \"{}\" was cancelled by the user'.format(self.name))\n\n    def delete(self):\n        view = navigate_to(self, \"Details\")\n        view.configuration.item_select('Remove Catalog', handle_alert=True)\n        view = self.create_view(CatalogsView, wait='10s')\n        view.flash.assert_no_error()\n        view.flash.assert_success_message(\n            'Catalog \"{}\": Delete successful'.format(self.description or self.name))\n\n    @property\n    def exists(self):\n        try:\n            navigate_to(self, 'Details')\n            return True\n        except (NameError, CandidateNotFound):\n            return False\n\n\n@attr.s\nclass CatalogCollection(BaseCollection):\n    \"\"\"A collection for the :py:class:`cfme.services.catalogs.catalog.Catalog`\"\"\"\n    ENTITY = Catalog\n\n    def create(self, name, description, items=None):\n        \"\"\"Create a catalog.\n\n        Args:\n            name: The name of the catalog\n            description: The description of the catalog\n            items: Items in the catalog\n        \"\"\"\n        view = navigate_to(self, 'Add')\n        view.fill({\n            'name': name,\n            'description': description,\n            'assign_catalog_items': items\n        })\n        view.add_button.click()\n        catalog = self.instantiate(name=name, description=description, items=items)\n        view = self.create_view(CatalogsView)\n        assert view.is_displayed\n        view.flash.assert_no_error()\n        return catalog\n\n\n@navigator.register(CatalogCollection)\nclass All(CFMENavigateStep):\n    VIEW = CatalogsView\n    prerequisite = NavigateToAttribute('appliance.server', 'LoggedIn')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.navigation.select('Services', 'Catalogs')\n        self.view.catalogs.tree.click_path(\"All Catalogs\")\n\n\n@navigator.register(CatalogCollection)\nclass Add(CFMENavigateStep):\n    VIEW = AddCatalogView\n    prerequisite = NavigateToSibling('All')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.configuration.item_select('Add a New Catalog')\n\n\n@navigator.register(Catalog)\nclass Details(CFMENavigateStep):\n    VIEW = DetailsCatalogView\n    prerequisite = NavigateToAttribute('parent', 'All')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.catalogs.tree.click_path(\"All Catalogs\", self.obj.name)\n\n\n@navigator.register(Catalog)\nclass Edit(CFMENavigateStep):\n    VIEW = EditCatalogView\n    prerequisite = NavigateToSibling('Details')\n\n    def step(self, *args, **kwargs):\n        self.prerequisite_view.configuration.item_select('Edit this Item')\n", "path": "cfme/services/catalogs/catalog.py"}]}