-
Notifications
You must be signed in to change notification settings - Fork 3
Description
A number of our libraries are failing in CI for one of two reasons:
- They directly import from a package that isn't explicitly listed as a dependency in their
spago.dhall
file - They contain unused names in their code (ie. an unused function, or an unused argument, or a destructured value that is never used...)
They need to be fixed by taking actions depending on whether they're failing due to the unused names or the transitive dependencies. If you would like to be included in the CHANGELOG you are free to add an entry under the "Other improvements" section (for example: Ensure all imported packages are in the spago.dhall file (#000 by @___)
).
Don't bother updating the bower.json files -- I can take care of this later on!
To fix a library that imports from a transitive dependency:
- Follow the instructions Spago includes about installing missing libraries -- this can basically be copy/pasted into a call to
spago install
. For example, if Spago reports that a library imports fromprelude
but doesn't list it as a dependency, then you can fix the issue withspago install prelude
. - If there are warnings about unused dependencies, then remove the libraries that Spago has identified as unused from the package's
spago.dhall
file. This has to be done manually -- there is nouninstall
command.
To fix a library that has an UnusedName
error from the compiler:
- If the error is reported on a top-level declaration that is unused and not exported, then remove the declaration. (If it should be exported instead, then it will be caught in code review.)
- If the error is about a declaration that is unused, then remove the declaration.
- If the error results from destructuring (for example, destructuring a record
{ a, b }
but one or more of the names is unused), then remove the unused names.
When you fix one of these libraries, please include a link to this issue in the pull request so that it automatically shows up on this issue. These libraries need to be fixed:
- nullable (example failure)
- now (example failure)
- matryoshka (example failure)
- js-uri (example failure)
- js-timers (example failure)
- js-date (example failure)
- freet (example failure)
- fork (example failure)
- fixed-points (example failure)
- coroutines (example failure)
- concurrent-queues (example failure)
- avar (example failure)
- argonaut-traversals (example failure)
- argonaut-core (example failure)
- argonaut-codecs (example failure)
- argonaut (example failure)
- affjax (example failure)
- aff-coroutines (example failure)
- aff-bus (example failure)
- aff (example failure)