Skip to content

ValueError in repr for default SkyCoord #2613

Closed

Description

@cdeil

I guess this repr for a default SkyCoord is not the intended behaviour?

In [5]: from astropy.coordinates import SkyCoord

In [6]: SkyCoord()
Out[6]: <repr(<astropy.coordinates.sky_coordinate.SkyCoord at 0x1070a1a90>) failed: ValueError: substring not found>

cc @eteq @taldcroft

Activity

  1. taldcroft commented on Jun 10, 2014

    @taldcroft
    Member

    That's a bug, but not in the way you imply. Passing no data to SkyCoord should raise a meaningful exception since data are always required here.

  2. added this to the v0.4.0 milestone on Jun 10, 2014
  3. cdeil commented on Jun 10, 2014

    @cdeil
    MemberAuthor

    I didn't read the new docs yet, so I didn't know if there are use cases where SkyCoord doesn't need data. But sure, failing SkyCoord() at construction if no data are passed makes sense to me.

  4. eteq commented on Jun 12, 2014

    @eteq
    Member

    @taldcroft - should I wait on trying to fix this until #2586 is done? I presume it will conflict... (or if you want to fix it there, that's fine too)

  5. taldcroft commented on Jun 12, 2014

    @taldcroft
    Member

    @eteq - yes please wait on #2586, or base a branch on that assuming there won't be too many more conflicting commits at this point.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions