Skip to content

Remove --enable-legacy functionality#1493

Merged
eteq merged 1 commit intoastropy:masterfrom
astrofrog:remove-legacy
Oct 25, 2013
Merged

Remove --enable-legacy functionality#1493
eteq merged 1 commit intoastropy:masterfrom
astrofrog:remove-legacy

Conversation

@astrofrog
Copy link
Member

As mentioned in #1488, I would like to propose removing the ability to do --enable-legacy altogether. I've never come across users that make use of it, and as the APIs of Astropy and other packages diverges in future, I think it will actually no longer be correct to enable these legacy layers anyway. Is there any benefit to keeping them around? (as shown in #1488, this functionality broke, and none of us caught it, so if we want to keep it, we have to test it more).

@cdeil
Copy link
Member

cdeil commented Sep 29, 2013

I was using pyfits via --enable-legacy. After running into issue #1488 I updated the import pyfits to from astropy.io import fits in all my code, which took only a few minutes. It should be easy for everyone else to update their package and scripts, too. +1 to removing --enable-legacy now.

Note that --enable-legacy often refuses to install astropy like this:

$ python setup.py install --enable-legacy --user
------------------------------------------------------------
The compatibility packages cannot be installed because the
following legacy packages are already installed:
    * pyfits
    * vo
    * pywcs

The compatibility packages can only be installed if none of
the corresponding legacy packages are present.
------------------------------------------------------------

I did get this on a machine where a very old pyfits version was installed in the system Python site-packages and I wanted to install a recent version of pyfits and astropy in the user site-packages ... refusing to install the pyfits legacy shim was not the behaviour I wanted in this case.

@astrofrog
Copy link
Member Author

I'm going to attach a pull request to this issue - it doesn't mean we should merge it, but it's there in case we want to.

@astrofrog
Copy link
Member Author

Hey look @taldcroft, it's your favorite kind of pull request ;)

@taldcroft
Copy link
Member

👍

@mdboom
Copy link
Contributor

mdboom commented Sep 30, 2013

👍, even though we're flushing many hours of figuring out dark recesses of Python package installation down the drain 😉

@astrofrog
Copy link
Member Author

@mdboom - yeah, I do feel a little sad when we get rid of things that were so painful to put in place! I'm just hoping it will save us more hours of maintaining it ;)

Anyway, this is just a suggestion and if people feel we should keep it, then I'm open!

@olebole
Copy link
Member

olebole commented Oct 1, 2013

[copying from my posting to astropy-devel]
I have a slightly opposite view. There is very much older software flying around that still uses pyfits and pywcs. And they will continue at least until astropy-1.0 is out (but probably years longer).

Astropy-legacy would allow to drop the standalone pyfits/pywcs packages very soon and still keep this older software. And, at the end, the transition would be easier, since they already use the identical code (just with a different name). This lowers the psychological barrier for the transition.

What I would propose:

  • keep astropy-legacy
  • remove pyfits, pywcs, and vo.table in favour of astropy-legacy once astropy-1.0 is out
  • on some later time, mark the legacy packages as deprecated.

I must, however, also state that the use of the legacy packages so far in Debian is negliglible, as far as the limited statistics can tell: 18 installations of astropy, but only one for -legacy. pywcs has 39, pyfits 177 installations. So, I feel still free to remove the legacy packages.

@astrofrog
Copy link
Member Author

@embray @perrygreenfield - do you have any opinions on this?

@embray
Copy link
Member

embray commented Oct 14, 2013

I don't have any strong feelings I don't think. It was a neat hack and I wish it could have had more uptake, but it seems like in practice it's been easier for people to just make the switch. I'm all for removing code until there's nothing left to remove :)

@eteq
Copy link
Member

eteq commented Oct 18, 2013

Just so we're clear, merging this would mean removing the astropy-legacy from debian, but leaving in pyfits, pywcs and vo.table for the forseeable future, right @olebole (possible eventually deprecating them, though?)

I'm fine with that plan. I agree with @embray that it seems more like anyone who actually is willing to bother installing astropy is willing to switch to astropy.io.*...

@olebole
Copy link
Member

olebole commented Oct 19, 2013

OK, so let's remove the legacy code here. Switching is really easy, and the legacy option will have problems with the version numbers anyway...

@astrofrog
Copy link
Member Author

I will merge this pull request in a few hours if there are no other comments! If we ever want to re-enable this kind of functionality, at least we have the current code in the git history to start from.

eteq added a commit that referenced this pull request Oct 25, 2013
Remove --enable-legacy functionality
@eteq eteq merged commit f6466c5 into astropy:master Oct 25, 2013
@mindw
Copy link

mindw commented Nov 23, 2013

Please note that the above broke compatibility with scikit.image and veusz and it's no longer possible to use astropy as a replacement for pyfits.
It would minimize the noise if the needed changes are pushed to the above projects.

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

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants