Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove legacy code from code base #10262

Open
5 tasks
mpickering opened this issue Aug 19, 2024 · 5 comments
Open
5 tasks

Remove legacy code from code base #10262

mpickering opened this issue Aug 19, 2024 · 5 comments

Comments

@mpickering
Copy link
Collaborator

Cabal and cabal-install have a large amount of legacy code.

Much legacy code for supporting different Haskell compilers, which is surely bitrotted at this point (untested on CI)

  • Support for UHC
  • Support for GHCJS
  • Support for Haskell Suite

v1-commands have been deprecated for a long while

  • Remove v1-commands

nix support is also legacy and unused to my knowledge

  • Remove nix support

Please contribute to this issue by listing any other legacy parts of the code base which should be removed.

The cost of these code paths is real, they must also be updated when performing refactoring or other improvements (see #10256 for example).

@alt-romes
Copy link
Collaborator

alt-romes commented Aug 19, 2024

I'm very much in favour of this. Even if some of these are more contentious, surely we can make progress on the undisputed ones.

Cabal should become rid of legacy baggage before growing new features, IMO.

@ulysses4ever
Copy link
Collaborator

There are many issues discussing parts of this meta-issue and they should be referenced, I think. Esp. regarding v1 and nix.

@geekosaur
Copy link
Collaborator

People are definitely still using both v1-commands and ghcjs.

@andreasabel
Copy link
Member

andreasabel commented Aug 27, 2024

@mpickering wrote:

[ ] Remove v1-commands

Relevant issue collections include:

On the danger of repeating myself: I first want to see feature completeness of v2 over v1.
One main limitation for me is that v2-install will unconditionally rebuild all modules, in contrast to v1-install or v2-build. Thus, it is unfeasible to run an automatic git bisect process based on cabal v2-install.
However, in our agda-bisect tool we need an efficient way of generating for the current bisecting point an Agda executable that we can pass to a script that runs some test on this version of Agda. And Agda accesses data-files so the context should also be correct (something one does not have to worry about with v1-install).
One resolution for me would probably if one could invoke cabal run from somewhere outside of the project, but a respective feature request has not been fulfilled:

Update: cabal run --project-dir=... works now (!); I could evaluate again if this will work in our context.

@ulysses4ever
Copy link
Collaborator

Hackage builder still uses V1 command afaiu. It may be a great bite-size task to solve before doing away with V1. Almost gsoc size, maybe.

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

No branches or pull requests

5 participants