haskell
haskell copied to clipboard
Add a disclaimer about version constraints and Stackage
At the moment, the Haskell track allows editing the package.yaml
.
Yes, it is unclear that any version (using a version constraint) wouldn't work, since a specific version of Stackage is used behind the scenes.
If a version constraint cannot be satisfied, a test run fails with:
No information from Hackage index, updating
Selected mirror https://hackage.haskell.org/
Downloading root
HttpExceptionRequest Request {
host = "hackage.haskell.org"
port = 443
secure = True
requestHeaders = [("Accept-Encoding",""),("User-Agent","Haskell pantry package")]
path = "/root.json"
queryString = ""
method = "GET"
proxy = Nothing
rawBody = False
redirectCount = 10
responseTimeout = ResponseTimeoutDefault
requestVersion = HTTP/1.1
}
(ConnectionFailure Network.Socket.getAddrInfo (called with preferred socket type/protocol: AddrInfo {addrFlags = [AI_ADDRCONFIG], addrFamily = AF_UNSPEC, addrSocketType = Stream, addrProtocol = 0, addrAddress = <assumed to be undefined>, addrCanonName = <assumed to be undefined>}, host name: Just "hackage.haskell.org", service name: Just "443"): does not exist (Try again))
Exercises in the track are designed to be basic, so it's unlikely that someone might need more than some common functions - e.g., the latest version of some library. A disclaimer like the one below should probably be enough in the package.yaml
:
# Do not specify version bounds!
# Versions are derived from the Stackage snapshot.
Even better if those files can be autogenerated with the version of Stackage specified as well.
Check the initial discussion here: https://github.com/exercism/haskell/issues/1041