Skip to content

Move library to dhall-core package #1102

Open
@f-f

Description

@f-f

As @Gabriel439 explained in #1096 (comment):

the main issue we're running into is that the dhall package is actually doing two separate things:

  • Providing a native Haskell binding
  • Providing the dhall executable

If we could split out the native Haskell binding into a smaller separate package (i.e. dhall-core or dhall-api) and leave the dhall package for the executable (and re-exporting the Haskell API for backwards compatibility) then I'd have fewer reservations about adding extra dependencies to the dhall package. The reason why is that I'd like people using dhall as a native Haskell binding to have a smaller dependency footprint.

For example, if they were separate packages then somebody using the executable-free package to configure their Haskell program wouldn't need to depend on repline, aeson, aeson-pretty, Diff, dotgen, cborg-json, or ansi-terminal. Similarly, we could freely add dependencies like yaml to the executable package guilt-free.

I'll add that:

  • I agree that this separation would be greatly beneficial for downstream packages, e.g. in spago we have issues on some OSs because the repline package dynamically links to the native libterminfo (I guess we could statically compile releases, but I'd say just not depending on repline would be an easier option)
  • Should we also split off dhall-json-core from its executable package?

Metadata

Metadata

Assignees

No one assigned

    Labels

    buildBuilding, testing, installing, packaging, etc

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions