We are currently solving the following issue within our repository. Here is the issue text:
--- BEGIN ISSUE ---
EIT data fails with wcsaxes
The wcs information in the EIT header is not being identified as celestial axes by wcslib (inside astropy.wcs). This means that wcs is not detecting them as angular axes properly so therefore the set to arcsecond formatting is failing.


--- END ISSUE ---

Below are some code segments, each from a relevant file. One or more of these files may contain bugs.
--- BEGIN FILES ---
Path: `sunpy/visualization/wcsaxes_compat.py`
Content:
```
1 # -*- coding: utf-8 -*-
2 """
3 Helpers and Functions to make WCSAxes work in SunPy
4 """
5 import warnings
6 
7 import matplotlib.pyplot as plt
8 
9 import astropy.units as u
10 
11 try:
12     import wcsaxes
13     HAVE_WCSAXES = True
14 
15 except ImportError:
16     HAVE_WCSAXES = False
17     warnings.warn("SunPy plotting is improved by installing the WCSAxes module: http://wcsaxes.readthedocs.org/en/latest/index.html")
18 
19 FORCE_NO_WCSAXES = False
20 
21 __all__ = ['HAVE_WCSAXES', 'is_wcsaxes', 'FORCE_NO_WCSAXES']
22 
23 def is_wcsaxes(axes):
24     """
25     Test a matplotlib Axes object to see if it is an instance of WCSAxes
26 
27     Parameters
28     ----------
29     axes : matplotlib Axes Object
30         Axes to test
31 
32     Returns
33     -------
34     result : bool
35         Result of the test
36     """
37 
38     if HAVE_WCSAXES and not FORCE_NO_WCSAXES:
39         return isinstance(axes, wcsaxes.WCSAxes)
40     else:
41         return False
42 
43 
44 def gca_wcs(wcs, fig=None):
45     """
46     Get the current axes, and return a WCSAxes if possible
47     """
48 
49     if not fig:
50         fig = plt.gcf()
51 
52     if not len(fig.get_axes()):
53         if HAVE_WCSAXES and not FORCE_NO_WCSAXES:
54             ax = plt.gca(projection=wcs)
55         else:
56             ax = plt.gca()
57 
58     else:
59         ax = plt.gca()
60 
61     return ax
62 
63 def get_world_transform(axes):
64     if is_wcsaxes(axes):
65         transform = axes.get_transform('world')
66     else:
67         transform = axes.transData
68 
69     return transform
70 
71 def default_wcs_grid(axes):
72     """
73     Apply some default wcsaxes grid formatting
74     """
75     if not isinstance(axes, wcsaxes.WCSAxes):
76         raise TypeError("This axes is not a WCSAxes")
77 
78     x = axes.coords[0]
79     y = axes.coords[1]
80 
81     x.set_ticks(color='white')
82     y.set_ticks(color='white')
83 
84     x.set_ticks_position('bl')
85     y.set_ticks_position('bl')
86 
87     x.set_major_formatter('s.s')
88     y.set_major_formatter('s.s')
89 
90     axes.coords.grid(color='white', alpha=0.6)
91 
92 def wcsaxes_heliographic_overlay(axes):
93     """
94     Draw a heliographic overlay using wcsaxes
95     """
96     overlay = axes.get_coords_overlay('heliographicstonyhurst')
97 
98     lon = overlay[0]
99     lat = overlay[1]
100 
101     lon.coord_wrap = 180
102     lon.set_major_formatter('dd')
103 
104     lon.set_axislabel('Solar Longitude')
105     lat.set_axislabel('Solar Latitude')
106 
107     lon.set_ticks_position('tr')
108     lat.set_ticks_position('tr')
109 
110     lon.set_ticks(spacing=10. * u.deg, color='white')
111     lat.set_ticks(spacing=10. * u.deg, color='white')
112 
113     overlay.grid(color='white', alpha=0.5)
114 
115     return overlay
116
```
--- 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/sunpy/visualization/wcsaxes_compat.py b/sunpy/visualization/wcsaxes_compat.py
--- a/sunpy/visualization/wcsaxes_compat.py
+++ b/sunpy/visualization/wcsaxes_compat.py
@@ -84,6 +84,11 @@
     x.set_ticks_position('bl')
     y.set_ticks_position('bl')
 
+    if x.coord_type != 'longitude':
+        x.set_coord_type('longitude', coord_wrap=180.)
+    if y.coord_type != 'latitude':
+        y.set_coord_type('latitude')
+
     x.set_major_formatter('s.s')
     y.set_major_formatter('s.s')

{"golden_diff": "diff --git a/sunpy/visualization/wcsaxes_compat.py b/sunpy/visualization/wcsaxes_compat.py\n--- a/sunpy/visualization/wcsaxes_compat.py\n+++ b/sunpy/visualization/wcsaxes_compat.py\n@@ -84,6 +84,11 @@\n     x.set_ticks_position('bl')\n     y.set_ticks_position('bl')\n \n+    if x.coord_type != 'longitude':\n+        x.set_coord_type('longitude', coord_wrap=180.)\n+    if y.coord_type != 'latitude':\n+        y.set_coord_type('latitude')\n+\n     x.set_major_formatter('s.s')\n     y.set_major_formatter('s.s')\n", "issue": "EIT data fails with wcsaxes\nThe wcs information in the EIT header is not being identified as celestial axes by wcslib (inside astropy.wcs). This means that wcs is not detecting them as angular axes properly so therefore the set to arcsecond formatting is failing.\n\n", "before_files": [{"content": "# -*- coding: utf-8 -*-\n\"\"\"\nHelpers and Functions to make WCSAxes work in SunPy\n\"\"\"\nimport warnings\n\nimport matplotlib.pyplot as plt\n\nimport astropy.units as u\n\ntry:\n    import wcsaxes\n    HAVE_WCSAXES = True\n\nexcept ImportError:\n    HAVE_WCSAXES = False\n    warnings.warn(\"SunPy plotting is improved by installing the WCSAxes module: http://wcsaxes.readthedocs.org/en/latest/index.html\")\n\nFORCE_NO_WCSAXES = False\n\n__all__ = ['HAVE_WCSAXES', 'is_wcsaxes', 'FORCE_NO_WCSAXES']\n\ndef is_wcsaxes(axes):\n    \"\"\"\n    Test a matplotlib Axes object to see if it is an instance of WCSAxes\n\n    Parameters\n    ----------\n    axes : matplotlib Axes Object\n        Axes to test\n\n    Returns\n    -------\n    result : bool\n        Result of the test\n    \"\"\"\n\n    if HAVE_WCSAXES and not FORCE_NO_WCSAXES:\n        return isinstance(axes, wcsaxes.WCSAxes)\n    else:\n        return False\n\n\ndef gca_wcs(wcs, fig=None):\n    \"\"\"\n    Get the current axes, and return a WCSAxes if possible\n    \"\"\"\n\n    if not fig:\n        fig = plt.gcf()\n\n    if not len(fig.get_axes()):\n        if HAVE_WCSAXES and not FORCE_NO_WCSAXES:\n            ax = plt.gca(projection=wcs)\n        else:\n            ax = plt.gca()\n\n    else:\n        ax = plt.gca()\n\n    return ax\n\ndef get_world_transform(axes):\n    if is_wcsaxes(axes):\n        transform = axes.get_transform('world')\n    else:\n        transform = axes.transData\n\n    return transform\n\ndef default_wcs_grid(axes):\n    \"\"\"\n    Apply some default wcsaxes grid formatting\n    \"\"\"\n    if not isinstance(axes, wcsaxes.WCSAxes):\n        raise TypeError(\"This axes is not a WCSAxes\")\n\n    x = axes.coords[0]\n    y = axes.coords[1]\n\n    x.set_ticks(color='white')\n    y.set_ticks(color='white')\n\n    x.set_ticks_position('bl')\n    y.set_ticks_position('bl')\n\n    x.set_major_formatter('s.s')\n    y.set_major_formatter('s.s')\n\n    axes.coords.grid(color='white', alpha=0.6)\n\ndef wcsaxes_heliographic_overlay(axes):\n    \"\"\"\n    Draw a heliographic overlay using wcsaxes\n    \"\"\"\n    overlay = axes.get_coords_overlay('heliographicstonyhurst')\n\n    lon = overlay[0]\n    lat = overlay[1]\n\n    lon.coord_wrap = 180\n    lon.set_major_formatter('dd')\n\n    lon.set_axislabel('Solar Longitude')\n    lat.set_axislabel('Solar Latitude')\n\n    lon.set_ticks_position('tr')\n    lat.set_ticks_position('tr')\n\n    lon.set_ticks(spacing=10. * u.deg, color='white')\n    lat.set_ticks(spacing=10. * u.deg, color='white')\n\n    overlay.grid(color='white', alpha=0.5)\n\n    return overlay\n", "path": "sunpy/visualization/wcsaxes_compat.py"}], "after_files": [{"content": "# -*- coding: utf-8 -*-\n\"\"\"\nHelpers and Functions to make WCSAxes work in SunPy\n\"\"\"\nimport warnings\n\nimport matplotlib.pyplot as plt\n\nimport astropy.units as u\n\ntry:\n    import wcsaxes\n    HAVE_WCSAXES = True\n\nexcept ImportError:\n    HAVE_WCSAXES = False\n    warnings.warn(\"SunPy plotting is improved by installing the WCSAxes module: http://wcsaxes.readthedocs.org/en/latest/index.html\")\n\nFORCE_NO_WCSAXES = False\n\n__all__ = ['HAVE_WCSAXES', 'is_wcsaxes', 'FORCE_NO_WCSAXES']\n\ndef is_wcsaxes(axes):\n    \"\"\"\n    Test a matplotlib Axes object to see if it is an instance of WCSAxes\n\n    Parameters\n    ----------\n    axes : matplotlib Axes Object\n        Axes to test\n\n    Returns\n    -------\n    result : bool\n        Result of the test\n    \"\"\"\n\n    if HAVE_WCSAXES and not FORCE_NO_WCSAXES:\n        return isinstance(axes, wcsaxes.WCSAxes)\n    else:\n        return False\n\n\ndef gca_wcs(wcs, fig=None):\n    \"\"\"\n    Get the current axes, and return a WCSAxes if possible\n    \"\"\"\n\n    if not fig:\n        fig = plt.gcf()\n\n    if not len(fig.get_axes()):\n        if HAVE_WCSAXES and not FORCE_NO_WCSAXES:\n            ax = plt.gca(projection=wcs)\n        else:\n            ax = plt.gca()\n\n    else:\n        ax = plt.gca()\n\n    return ax\n\ndef get_world_transform(axes):\n    if is_wcsaxes(axes):\n        transform = axes.get_transform('world')\n    else:\n        transform = axes.transData\n\n    return transform\n\ndef default_wcs_grid(axes):\n    \"\"\"\n    Apply some default wcsaxes grid formatting\n    \"\"\"\n    if not isinstance(axes, wcsaxes.WCSAxes):\n        raise TypeError(\"This axes is not a WCSAxes\")\n\n    x = axes.coords[0]\n    y = axes.coords[1]\n\n    x.set_ticks(color='white')\n    y.set_ticks(color='white')\n\n    x.set_ticks_position('bl')\n    y.set_ticks_position('bl')\n\n    if x.coord_type != 'longitude':\n        x.set_coord_type('longitude', coord_wrap=180.)\n    if y.coord_type != 'latitude':\n        y.set_coord_type('latitude')\n\n    x.set_major_formatter('s.s')\n    y.set_major_formatter('s.s')\n\n    axes.coords.grid(color='white', alpha=0.6)\n\ndef wcsaxes_heliographic_overlay(axes):\n    \"\"\"\n    Draw a heliographic overlay using wcsaxes\n    \"\"\"\n    overlay = axes.get_coords_overlay('heliographicstonyhurst')\n\n    lon = overlay[0]\n    lat = overlay[1]\n\n    lon.coord_wrap = 180\n    lon.set_major_formatter('dd')\n\n    lon.set_axislabel('Solar Longitude')\n    lat.set_axislabel('Solar Latitude')\n\n    lon.set_ticks_position('tr')\n    lat.set_ticks_position('tr')\n\n    lon.set_ticks(spacing=10. * u.deg, color='white')\n    lat.set_ticks(spacing=10. * u.deg, color='white')\n\n    overlay.grid(color='white', alpha=0.5)\n\n    return overlay\n", "path": "sunpy/visualization/wcsaxes_compat.py"}]}