[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: lens build failures



We use OverloadedStrings in some doctests here and there.

Doctest recycles an existing GHC session as it switches between modules. This lets its runtime be linear in the module count rather than quadratic and makes evn the base constants much better.

Unfortunately that means that when we have

-- $setup
-- >>> :set -XOverloadedStrings

in one module, that flag remains on when testing subsequent modules until something explicitly turns it off.

What is happening here is PowerPC happened to visit the modules in a different order than normal and we happened to accidentally omit the

-- $setup
-- >>> :set -XNoOverloadedStrings

on that module to turn it back off, and it had been masked by the fact that the traversal order (determined by the order doctest found the source files by scanning the directory) is different on that platform.

Fortunately, it is a one line fix and I just applied it in HEAD.

-Edward


On Wed, May 14, 2014 at 11:53 PM, Joachim Breitner <nomeata@debian.org> wrote:
Hi,

Am Mittwoch, den 14.05.2014, 12:34 +0200 schrieb Joachim Breitner:
> new error that I haven’t seen before, and that occurs only one one
> architecture so far:
>
> debian/hlibrary.setup test --builddir=dist-ghc --show-details=always
> Running 4 test suites...
> Test suite doctests: RUNNING...
> ### Failure in src/Data/Map/Lens.hs:38: _expression_ `ix 2 %~ ("New " ++) $ Map.fromList [(2, "Earth")]'
> expected: fromList [(2,"New Earth")]
>  but got:
>           <interactive>:1182:10:
>               No instance for (Data.String.IsString [a0])
>                 arising from the literal `"New "'
>               The type variable `a0' is ambiguous
>               Possible fix: add a type signature that fixes these type variable(s)
>               Note: there is a potential instance available:
>                 instance Data.String.IsString [Char] -- Defined in `Data.String'
>               Possible fix:
>                 add an instance declaration for (Data.String.IsString [a0])
>               In the first argument of `(++)', namely `"New "'
>               In the second argument of `(%~)', namely `("New " ++)'
>               In the _expression_: ix 2 %~ ("New " ++)
> Examples: 794  Tried: 791  Errors: 0  Failures: 1
> Test suite doctests: FAIL
> https://buildd.debian.org/status/fetch.php?pkg=haskell-lens&arch=powerpc&ver=4.1.2-3&stamp=1400063159
>
> This is really weird: Version 4.1.2-2 built on powerpc, and the only
> differences seems to be that the hlint tests are disabled in the latter
> build.
>
> /me reschedules the build to see if it is deterministic.

very weird. It is not deterministic:
https://buildd.debian.org/status/fetch.php?pkg=haskell-lens&arch=powerpc&ver=4.1.2-3&stamp=1400065753
Exactly the same Haskell related packages, only version differences in
things like binutils or libc. Haven’t seen anything like that before.
But it works now, so *shrug*

Greetigs,
Joachim

--
Joachim "nomeata" Breitner
Debian Developer
  nomeata@debian.org | ICQ# 74513189 | GPG-Keyid: F0FBF51F
  JID: nomeata@joachim-breitner.de | http://people.debian.org/~nomeata



Reply to: