joshuaclayton/unused

Brew install error on MacOS 10.13.3

Closed this issue · 5 comments

Using Homebrew 1.5.10 on a relatively clean system:

~/ ❯❯❯ brew install unused                                                                                                                                                                                                                  ✘ 1 5523_retire_form_wizard
==> Installing unused from joshuaclayton/formulae
==> Downloading https://github.com/joshuaclayton/unused/archive/v0.8.0.0.tar.gz
Already downloaded: /Users/USER/Library/Caches/Homebrew/unused-0.8.0.0.tar.gz
==> cabal sandbox init
==> cabal update
==> cabal install --jobs=4 --max-backjumps=100000 --only-dependencies
==> cabal install --jobs=4 --max-backjumps=100000 --prefix=/usr/local/Cellar/unused/0.8.0.0
Last 15 lines from /Users/USER/Library/Logs/Homebrew/unused/04.cabal:
        PB.startProgress (PB.msg message) PB.percentage progressBarWidth
      In an equation for ‘buildProgressBar’:
          buildProgressBar
            = PB.startProgress (PB.msg message) PB.percentage progressBarWidth
            where
                message = "Working"
                progressBarWidth = 60
   |
50 |     PB.startProgress (PB.msg message) PB.percentage progressBarWidth
   |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
cabal: Leaving directory '.'
cabal: Error: some packages failed to install:
unused-0.8.0.0-KNld5vfKrcU2Fk1URaeNGX failed during the building phase. The
exception was:
ExitFailure 1

If reporting this issue please do so at (not Homebrew/brew or Homebrew/core):
https://github.com/joshuaclayton/homebrew-formulae/issues

These open issues may also help:
Unable to install (MacOS 10.12.2 -- unused 0.6.1.0) https://github.com/joshuaclayton/homebrew-formulae/issues/3

Similar happened when trying to install via stack.

# LOTS OF OTHER STUFF ABOVE
unused-0.8.0.0: download
unused-0.8.0.0: configure
unused-0.8.0.0: build
Completed 51 action(s).

--  While building custom Setup.hs for package unused-0.8.0.0 using:
      /Users/davidfisher/.stack/setup-exe-cache/x86_64-osx/Cabal-simple_mPHDZzAJ_2.0.1.0_ghc-8.2.2 --builddir=.stack-work/dist/x86_64-osx/Cabal-2.0.1.0 build --ghc-options " -ddump-hi -ddump-to-file -fdiagnostics-color=always"
    Process exited with code: ExitFailure 1
    Logs have been written to: /Users/USER/.stack/global-project/.stack-work/logs/unused-0.8.0.0.log

    Configuring unused-0.8.0.0...
    Preprocessing library for unused-0.8.0.0..
    Building library for unused-0.8.0.0..
    [ 1 of 45] Compiling Common           ( src/Common.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Common.o )
    [ 2 of 45] Compiling Unused.CLI.ProgressIndicator.Types ( src/Unused/CLI/ProgressIndicator/Types.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Unused/CLI/ProgressIndicator/Types.o )
    [ 3 of 45] Compiling Unused.CLI.Util  ( src/Unused/CLI/Util.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Unused/CLI/Util.o )
    [ 4 of 45] Compiling Unused.CLI.ProgressIndicator.Internal ( src/Unused/CLI/ProgressIndicator/Internal.hs, .stack-work/dist/x86_64-osx/Cabal-2.0.1.0/build/Unused/CLI/ProgressIndicator/Internal.o )

    /private/var/folders/dd/zzy8nb_d5m19k7029869dffw0000gn/T/stack25041/unused-0.8.0.0/src/Unused/CLI/ProgressIndicator/Internal.hs:50:5: error:
        • Couldn't match type ‘async-2.1.1.1:Control.Concurrent.Async.Async
                                 ()’
                         with ‘CC.ThreadId’
          Expected type: Integer -> IO (PB.ProgressRef, CC.ThreadId)
            Actual type: PB.Progress
                         -> IO
                              (PB.ProgressRef, async-2.1.1.1:Control.Concurrent.Async.Async ())
        • In the expression:
            PB.startProgress (PB.msg message) PB.percentage progressBarWidth
          In an equation for ‘buildProgressBar’:
              buildProgressBar
                = PB.startProgress (PB.msg message) PB.percentage progressBarWidth
                where
                    message = "Working"
                    progressBarWidth = 60
       |
    50 |     PB.startProgress (PB.msg message) PB.percentage progressBarWidth
       |     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

@tibbon nice catch - looks like I didn't lock the progress bar package and it's causing issues.

Any interested in trying out this branch and reporting back? https://github.com/joshuaclayton/unused/tree/update-dependencies

Yea! That worked via stack build && stack install. Thanks for looking into it. Locking those versions seems to have fixed it.

@joshuaclayton I'm running into the same issue, but unfortunately the branch you created, https://github.com/joshuaclayton/unused/tree/update-dependencies, gives a 404
How do I fix?

@thecodeboss I've merged the PR (#94) so master has this work. Mind giving it a try?