Skip to content

Hackathon 2017

Mikhail Glushenkov edited this page Oct 13, 2017 · 12 revisions

This is a page to collect ideas for Cabal/Hackage hacking tasks/mini-projects for HaskellX2gether 2017. It is an updated version of a similar page for ZuriHac 2017.

Please use the #hackage IRC channel on freenode for online discussions.

Feel free to expand individual bullet points into full (linked) pages or tickets/issues.

Easy tickets suitable for beginners

If you're a newcomer to the Cabal code base, start by taking a look at the issues tagged "easy" and "newcomer" on the bug tracker. You should be able to find something to cut your teeth on there.

Strategically important projects

Mostly Cabal 2.2/3.0-related. 2.2 is the next release due in December. 3.0 is the more distant future version in which new-build will replace old build commands and sandboxes.


  • Improve cabal new-build

    new-build is a major reworking of how Cabal/cabal-install works internally that unifies old build commands and sandboxes and is the main focus of our efforts right now. See Edward's blog post for an intro to new-build and a more detailed explanation.

    There is a lot of work still to be done on new-build, and most of it can be done in parallel and in groups. We compiled the following list of tasks (roughly sorted by difficulty) that we feel are offering the most pay off right now and are suitable in scope for the hackathon:

    • 'cabal new-install' for binaries. See #3332 and 4558. There is a WIP patch by @fgaz at https://github.com/fgaz/cabal/tree/new-install/2, so it makes sense to start there. Should basically work just like cabal install foo does today for binaries modulo using the store for library dependencies. Should be relatively easy to implement (new-build foo + Setup.hs copy).
    • UX design for user-wide environments (cabal new-install). #3737.
    • Integration tests for new-build (e.g.: new-build everything on Stackage). #3322.
    • Fix this annoying bug: ghc-options applies to all dependencies, not just local packages. #3883.
    • Work on cabal new-update (index freezing by default, interaction with cabal.project.freeze). Talk with @ezyang and/or @hvr if they're online. #3832. There's an existing PR at #4809.
    • Go through the remaining issues in #3104 (difficulty: moderate)
    • Get the new-clean PR into shape.
    • Allow "sandbox without project file" functionality in new Cabal. #3730 (related to GHC environments, see extra-packages feature).
    • Go through the issues in the Galois meta tracking ticket: #3577.
    • Make cabal new-{test,bench} accept all arguments that cabal {test,bench} does. Relevant tickets: [#4643](https://github.com/haskell/cabal/issues/4643), [4766`](https://github.com/haskell/cabal/issues/4766).
    • Fix these remaining bugs in new-{run,test,bench}: #4619, #4676.
    • Improve cabal new-haddock.
    • Add support for git/darcs/... dependencies, #2189 (makes sense to start with tarball dependencies before tackling SCM ones -- tarballs are easier to test)
    • Support new-build projects in cabal outdated. #4627.
    • Take a look at this GitHub project compiled by @fgaz during HSoC and the nix-local-build tag on the bug tracker for additional ideas.

If the above is not enough, you can pick a task from the list of all open issues tagged new-build.


Not critically important, but good to have

  • Cabal documentation.

    Cabal's user guide got quite a bit better recently, but there's still a lot of room for improvement. In particular, we want to put more emphasis on the cabal-install tool at the expense of the Setup.hs interface and add a tutorial section. The new user guide TOC should look like roughly this:

    1. Intro
    2. Tutorial, p.1 - how to use cabal-install to build and install existing packages
    3. Tutorial, p.2 - how to develop programs using cabal-install and write .cabal files -- basically, an updated version of https://wiki.haskell.org/How_to_write_a_Haskell_program.
    4. .cabal format reference
    5. cabal-install command reference
    6. cabal new-build chapter
    7. Appendix: Cabal spec (i.e., the Setup.hs interface)

    Anyone considering this should feel empowered to make decisions. You could decide to start from scratch with a new structure and just pinch material from the existing docs. You might want to fully split into tutorial and reference.


  • A new website for cabal-install/Cabal.

    Our website hasn't been updated in ages, so a facelift is long due. It doesn't have to be super advanced, a simple Hakyll-based static page with a blog/news feed would suffice. Start by looking at the https://github.com/haskell/cabal-website repo.


  • Improvements in the release process.

    This is mainly about automating the process of producing binaries for various platforms (Linux i386/x86-64, OS X, Windows x32/x64). We can either use Travis and AppVeyor or the haskell.org infrastructure. The latter requires extending the code of GHC Builder to support arbitrary Haskell projects besides just GHC, because that's what they (haskell.org) want to use for their build farm. Talk with Gershom (@gbaz/@sclv) if he's online about haskell.org integration.


  • Add support for rust-files, analogous to c-files.

Maybe also other languages, like Objective C or Swift. Take a look at the recently merged PR #4810 that added support for cxx-files for inspiration.


  • Add a cabal typecheck command.

See #1176. Stretch goal: use this to add native support for Liquid Haskell (look at the existing integration as inspiration).


  • New AST for .cabal files (not an easy one!).

    Builds on the new Parsec parser work (see #2865). This should make it possible to programmatically edit .cabal files while preserving comments and formatting. Talk with @phadej or Duncan.

    See http://code.haskell.org/~duncan/cabal-ast-experiment/