adinapoli / threads-supervisor

Simple, IO-based Haskell library for Erlang-inspired thread supervisors
MIT License
29 stars 4 forks source link

won't compile #29

Closed thepixelmonk closed 5 years ago

thepixelmonk commented 5 years ago

latest build on hackage doesn't compile:

threads-supervisor-1.1.0.0: download
threads-supervisor-1.1.0.0: configure
threads-supervisor-1.1.0.0: build
Progress 2/3

--  While building package threads-supervisor-1.1.0.0 using:
      /home/toovs/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1 build --ghc-options " -ddump-hi -ddump-to-file -fdiagnostics-color=always"
    Process exited with code: ExitFailure 1
    Logs have been written to: /home/toovs/code/babblebot/.stack-work/logs/threads-supervisor-1.1.0.0.log

    Configuring threads-supervisor-1.1.0.0...
    Preprocessing library for threads-supervisor-1.1.0.0..
    Building library for threads-supervisor-1.1.0.0..
    [1 of 4] Compiling Control.Concurrent.Supervisor.Tutorial ( src/Control/Concurrent/Supervisor/Tutorial.hs, .stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Tutorial.o )
    [2 of 4] Compiling Control.Concurrent.Supervisor.Types ( src/Control/Concurrent/Supervisor/Types.hs, .stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Types.o )

    /tmp/stack-531e645c9d52d997/threads-supervisor-1.1.0.0/src/Control/Concurrent/Supervisor/Types.hs:82:16: error:
        • Couldn't match type ‘Int’ with ‘GHC.Natural.Natural’
          Expected type: Int -> IO (TBQueue a)
            Actual type: GHC.Natural.Natural -> IO (TBQueue a)
        • In the expression: newTBQueueIO
          In an equation for ‘newQueueIO’: newQueueIO = newTBQueueIO
          In the instance declaration for ‘QueueLike TBQueue’
       |
    82 |   newQueueIO = newTBQueueIO
adinapoli commented 5 years ago

Hey!

Which version of GHC and stm are you using? We recently merged support for GHC 8.* and the latest stm package, and I am wondering if that's the culprit.

On Sun, 20 Jan 2019, 02:10 Neill Bolton <notifications@github.com wrote:

latest build on hackage doesn't compile:

threads-supervisor-1.1.0.0: download

threads-supervisor-1.1.0.0: configure

threads-supervisor-1.1.0.0: build

Progress 2/3

-- While building package threads-supervisor-1.1.0.0 using:

  /home/toovs/.stack/setup-exe-cache/x86_64-linux-tinfo6/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.3 --builddir=.stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1 build --ghc-options " -ddump-hi -ddump-to-file -fdiagnostics-color=always"

Process exited with code: ExitFailure 1

Logs have been written to: /home/toovs/code/babblebot/.stack-work/logs/threads-supervisor-1.1.0.0.log

Configuring threads-supervisor-1.1.0.0...

Preprocessing library for threads-supervisor-1.1.0.0..

Building library for threads-supervisor-1.1.0.0..

[1 of 4] Compiling Control.Concurrent.Supervisor.Tutorial ( src/Control/Concurrent/Supervisor/Tutorial.hs, .stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Tutorial.o )

[2 of 4] Compiling Control.Concurrent.Supervisor.Types ( src/Control/Concurrent/Supervisor/Types.hs, .stack-work/dist/x86_64-linux-tinfo6/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Types.o )

/tmp/stack-531e645c9d52d997/threads-supervisor-1.1.0.0/src/Control/Concurrent/Supervisor/Types.hs:82:16: error:

    • Couldn't match type ‘Int’ with ‘GHC.Natural.Natural’

      Expected type: Int -> IO (TBQueue a)

        Actual type: GHC.Natural.Natural -> IO (TBQueue a)

    • In the expression: newTBQueueIO

      In an equation for ‘newQueueIO’: newQueueIO = newTBQueueIO

      In the instance declaration for ‘QueueLike TBQueue’

   |

82 |   newQueueIO = newTBQueueIO

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/adinapoli/threads-supervisor/issues/29, or mute the thread https://github.com/notifications/unsubscribe-auth/AAa-syz59LTDUxZh1cKDstVYEQ-ldINnks5vE8IdgaJpZM4aJacP .

DouglasBrunner commented 5 years ago

Same issue here.

I added your library to the a Stackage LST-13.16 project that's using GHC 8.6.4.

The STM version in use is STM-2.5.0.0

580       /home/doug/.stack/setup-exe-cache/x86_64-linux/Cabal-simple_mPHDZzAJ_2.4.0.1_ghc-8.6.4 --builddir=.stack-work/dist/x86_64-linux/Cabal-2.4.0.1 build --ghc-options " -ddump-hi -ddump-to-file -fdia
581 gnostics-color=always"
582     Process exited with code: ExitFailure 1
583     Logs have been written to: /home/doug/dev/antigen/tbot/.stack-work/logs/threads-supervisor-1.1.0.0.log
584 
585     Configuring threads-supervisor-1.1.0.0...
586     Preprocessing library for threads-supervisor-1.1.0.0..
587     Building library for threads-supervisor-1.1.0.0..
588     [1 of 4] Compiling Control.Concurrent.Supervisor.Tutorial ( src/Control/Concurrent/Supervisor/Tutorial.hs, .stack-work/dist/x86_64-linux/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Tutorial.
589 o )
590     [2 of 4] Compiling Control.Concurrent.Supervisor.Types ( src/Control/Concurrent/Supervisor/Types.hs, .stack-work/dist/x86_64-linux/Cabal-2.4.0.1/build/Control/Concurrent/Supervisor/Types.o )
591 
592     /tmp/stack5768/threads-supervisor-1.1.0.0/src/Control/Concurrent/Supervisor/Types.hs:82:16: error:
593         • Couldn't match type ‘Int’ with ‘GHC.Natural.Natural’                                                                                                                                          
594           Expected type: Int -> IO (TBQueue a)                                                                                                                                                          
595             Actual type: GHC.Natural.Natural -> IO (TBQueue a)                                                                                                                                          
596         • In the expression: newTBQueueIO                                                                                                                                                               
597           In an equation for ‘newQueueIO’: newQueueIO = newTBQueueIO                                                                                                                                    
598           In the instance declaration for ‘QueueLike TBQueue’                                                                                                                                           
599        |
600     82 |   newQueueIO = newTBQueueIO
601        |                ^^^^^^^^^^^^
Mikolaj commented 5 years ago

I hope it should be enough to publish master to Hackage. That would be very useful for me as well.

adinapoli commented 5 years ago

@Mikolaj added you as a maintainer on hackage and here (waiting for you to accept the invite link). Would you mind doing that yourself? 😛

Mikolaj commented 5 years ago

Fixed travis and uploaded to Hackage. Thank you, Alfredo!

Dear original reporters, please let us know if it works now for you.

DouglasBrunner commented 5 years ago

It compiles successfully now,

Thanks for the quick turnaround,