astropy/astropy — pull request #1760 by embray (2013-11-10 23:14:04+00:00)
Title: VO cone search not working due to issue in Spinner class

@pllim @mdboom - the following VO cone search example isn't working:

```
from astropy.vo.client import conesearch
from astropy import coordinates as coords
c = coords.ICRS.from_name('M31')
from astropy import units as u
twomass = 'Two Micron All Sky Survey (2MASS) 1'
result = conesearch.conesearch(c, 0.1 * u.degree, catalog_db=twomass)
```

gives:

```
Downloading http://stsdas.stsci.edu/astrolib/vo_databases/conesearch_good.json
|======================================================================================================================================================================================================================| 57k/ 57k (100.00%) 00s
Trying http://wfaudata.roe.ac.uk/twomass-dsa/DirectCone?DSACAT=TWOMASS&DSATAB=twomass_psc&
Downloading http://wfaudata.roe.ac.uk/twomass-dsa/DirectCone?DSACAT=TWOMASS&DSATAB=twomass_psc&SR=0.1&DEC=41.26875&RA=10.6847083&VERB=1 [Failed]
WARNING: W25: ?:?:?: W25: 'http://wfaudata.roe.ac.uk/twomass-dsa/DirectCone?DSACAT=TWOMASS&DSATAB=twomass_psc&' failed with: 'ascii' codec can't encode character u'\u25d3' in position 0: ordinal not in range(128) [astropy.io.votable.exceptions]
ERROR: VOSError: None of the available catalogs returned valid results. [astropy.vo.client.vos_catalog]
---------------------------------------------------------------------------
VOSError Traceback (most recent call last)
in ()
----> 1 result = conesearch.conesearch(c, 0.1 * u.degree, catalog_db=twomass)

/Users/tom/Library/Python/2.7/lib/python/site-packages/astropy-0.3.dev6508-py2.7-macosx-10.8-x86_64.egg/astropy/vo/client/conesearch.pyc in conesearch(center, radius, verb, **kwargs)
193
194 return vos_catalog.call_vo_service(CONESEARCH_DBNAME(),
--> 195 kwargs=args, **kwargs)
196
197

/Users/tom/Library/Python/2.7/lib/python/site-packages/astropy-0.3.dev6508-py2.7-macosx-10.8-x86_64.egg/astropy/vo/client/vos_catalog.pyc in call_vo_service(service_type, catalog_db, pedantic, verbose, cache, kwargs)
426 vo_warn(W25, (url, str(e)))
427
--> 428 raise VOSError('None of the available catalogs returned valid results.')
429
430

VOSError: None of the available catalogs returned valid results.
```

I'm working on the what's new document, hence how I found this. Is there a quick fix?

**EDIT: see my last comment for the cause of this bug**