haskell / ThreadScope

A graphical tool for profiling parallel Haskell programs
http://www.haskell.org/haskellwiki/ThreadScope
Other
154 stars 36 forks source link

Hackage bounds prevent builds with ghc-8.8 #102

Closed AndreasPK closed 4 years ago

AndreasPK commented 4 years ago

Trying with 8.8.1 on windows:

$ cabal new-install -w /e/ghc-8.8.1/bin/ghc.exe threadscope -j1
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Resolving dependencies...
Build profile: -w ghc-8.8.1 -O1
In order, the following will be built (use -v for more details):
 - threadscope-0.2.2 (exe:threadscope) (requires build)
cd_ C:\ghc\msys64\tmp\cabal-install.-908\dist-newstyle\tmp\src-908\threadscope-0.2.2
Warning: threadscope.cabal:7:8: Tabs used as indentation at 7:8, 8:8, 9:8,
10:8, 11:8, 12:8, 13:8
Configuring threadscope-0.2.2...
cd_ C:\ghc\msys64\tmp\cabal-install.-908\dist-newstyle\tmp\src-908\threadscope-0.2.2
Preprocessing executable 'threadscope' for threadscope-0.2.2..
Building executable 'threadscope' for threadscope-0.2.2..

<no location info>: warning: [-Wmissing-home-modules]
    These modules are needed for compilation but not listed in your .cabal file's other-modules:
        Paths_threadscope
[ 1 of 35] Compiling Events.EventDuration ( Events\EventDuration.hs, dist\build\threadscope\threadscope-tmp\Events\EventDuration.o )

Events\EventDuration.hs:89:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
   |
89 |   case spec event of
   |        ^^^^

Events\EventDuration.hs:92:32: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
   |
92 |      StartGC       -> gcStart (time event) events
   |                                ^^^^

Events\EventDuration.hs:98:36: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
   |
98 |     runDuration t = ThreadRun t s (time event) endTime
   |                                    ^^^^

Events\EventDuration.hs:105:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
105 |   case spec e of
    |        ^^^^

Events\EventDuration.hs:119:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
119 |   case spec event of
    |        ^^^^

Events\EventDuration.hs:127:14: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
127 |         t1 = time event
    |              ^^^^

Events\EventDuration.hs:132:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
132 |   case spec event of
    |        ^^^^

Events\EventDuration.hs:140:14: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
140 |         t1 = time event
    |              ^^^^

Events\EventDuration.hs:145:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
145 |   case spec event of
    |        ^^^^

Events\EventDuration.hs:153:14: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
153 |         t1 = time event
    |              ^^^^

Events\EventDuration.hs:158:8: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
158 |   case spec event of
    |        ^^^^

Events\EventDuration.hs:166:14: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
166 |         t1 = time event
    |              ^^^^

Events\EventDuration.hs:173:10: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
    |
173 |   = case spec e of
    |          ^^^^

Events\EventDuration.hs:174:37: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
174 |       StopThread{status=s} -> Just (time e, s)
    |                                     ^^^^
[ 2 of 35] Compiling Events.EventTree ( Events\EventTree.hs, dist\build\threadscope\threadscope-tmp\Events\EventTree.o )

Events\EventTree.hs:198:39: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
198 |   (s,e) = if null es then (0,0) else (time (head es), endTime)
    |                                       ^^^^

Events\EventTree.hs:226:17: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
226 |     EventSplit (time (head rhs))
    |                 ^^^^

Events\EventTree.hs:233:17: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
233 |     startTime = time (head es)
    |                 ^^^^

Events\EventTree.hs:260:9: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
    |
260 |     t = time e
    |         ^^^^
[ 3 of 35] Compiling Events.SparkStats ( Events\SparkStats.hs, dist\build\threadscope\threadscope-tmp\Events\SparkStats.o )
[ 4 of 35] Compiling Events.SparkTree ( Events\SparkTree.hs, dist\build\threadscope\threadscope-tmp\Events\SparkTree.o )

Events\SparkTree.hs:35:14: warning: [-Wdeprecations]
    In the use of ‘spec’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evSpec"
   |
35 |         case GHCEvents.spec event of
   |              ^^^^^^^^^^^^^^

Events\SparkTree.hs:37:27: warning: [-Wdeprecations]
    In the use of ‘time’
    (imported from GHC.RTS.Events, but defined in ghc-events-0.12.0:GHC.RTS.EventTypes):
    Deprecated: "The field is now called evTime"
   |
37 |             let endTime = GHCEvents.time event
   |                           ^^^^^^^^^^^^^^
[ 5 of 35] Compiling Events.HECs      ( Events\HECs.hs, dist\build\threadscope\threadscope-tmp\Events\HECs.o )

Events\HECs.hs:62:17: error:
    • The constructor ‘Event’ should have 3 arguments, but has been given 2
    • In the pattern: Event ts (UserMarker mark)
      In the pattern: CapEvent _ (Event ts (UserMarker mark))
      In a stmt of a list comprehension:
        CapEvent _ (Event ts (UserMarker mark)) <- elems
                                                     (hecEventArray hecs)
   |
62 |   | CapEvent _ (Event ts (UserMarker mark)) <- elems (hecEventArray hecs) ]
   |                 ^^^^^^^^^^^^^^^^^^^^^^^^^^
cabal.exe: Failed to build threadscope-0.2.2.
AndreasPK commented 4 years ago

Compilation from source works.

Specifiying the threadscope for building from hackage gives a bounds error:

$ cabal new-install -w /e/ghc-8.8.1/bin/ghc.exe threadscope-0.2.11.1 -j4
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Resolving dependencies...
cabal.exe: Could not resolve dependencies:
[__0] trying: threadscope-0.2.11.1 (user goal)
[__1] next goal: template-haskell (dependency of threadscope)
[__1] rejecting: template-haskell-2.15.0.0/installed-2.1... (conflict:
threadscope => template-haskell<2.14)
[__1] rejecting: template-haskell-2.15.0.0, template-haskell-2.14.0.0,
template-haskell-2.13.0.0, template-haskell-2.12.0.0,
template-haskell-2.11.1.0, template-haskell-2.11.0.0,
template-haskell-2.10.0.0, template-haskell-2.9.0.0, template-haskell-2.8.0.0,
template-haskell-2.7.0.0, template-haskell-2.6.0.0, template-haskell-2.5.0.0,
template-haskell-2.4.0.1, template-haskell-2.4.0.0, template-haskell-2.3.0.1,
template-haskell-2.3.0.0, template-haskell-2.2.0.0 (constraint from
non-upgradeable package requires installed instance)
[__1] fail (backjumping, conflict set: template-haskell, threadscope)
After searching the rest of the dependency tree exhaustively, these were the
goals I've had most trouble fulfilling: threadscope, template-haskell

I suspect all that needs to be done is bump the bounds on hackage via revision. Since it builds fine when I override the bounds:

$ cabal new-install -w /e/ghc-8.8.1/bin/ghc.exe threadscope-0.2.11.1 -j4 --allow-newer="template-haskell,base,ghc-events,gtk" --install-method=copy
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Warning: The package list for 'hackage.haskell.org' is 18 days old.
Run 'cabal update' to get the latest list of available packages.
Resolving dependencies...
Up to date
Copying 'threadscope.exe'
Mikolaj commented 4 years ago

Good to know, thank you. Whom do I call to get the hackage bounds bumped via revision?

@maoe: do we have any release pending/imminent that could also include bumped bounds?

AndreasPK commented 4 years ago

Good to know, thank you. Whom do I call to get the hackage bounds bumped via revision?

Maintainers have the ability to do revisions of the cabal file without reuploading. So do hackage trustees

Mikolaj commented 4 years ago

Oh, great, I forgot, thank you.

lapplislazuli commented 4 years ago

I get the exact same error (from cabal install) with cabal 2.4.0 and ghc 8.6.5

Mikolaj commented 4 years ago

If somebody would offer a PR with updated bounds, I will go and set them as Hackage revision ASAP. Unless current master is already fine?

maoe commented 4 years ago

I thought there was an issue that caused a build failure on some platform. Let me check.

maoe commented 4 years ago

https://github.com/gtk2hs/gtk2hs/issues/291 is the issue. I'll make a fix.

maoe commented 4 years ago

Working on a fix at https://github.com/haskell/ThreadScope/pull/103. Will continue tomorrow.

maoe commented 4 years ago

Released v0.2.12 on Hackage and confirmed cabal install works on Linux and macOS.

@AndreasPK @Twonki Could you try again?

lapplislazuli commented 4 years ago

@maoe having a new issue with pango.

It's rejecting pango-0.13 and below, and cannot find pango>=1.0 in my pkg-config database.

maoe commented 4 years ago

@Twonki Do you have pango installed on your system?

AndreasPK commented 4 years ago

New version works for me with both 8.6 and 8.8

$ cabal install threadscope
Resolving dependencies...
Build profile: -w ghc-8.6.5 -O1
In order, the following will be built (use -v for more details):
 - cairo-0.13.8.0 (lib:cairo) (requires build)
 - glib-0.13.8.0 (lib:glib) (requires build)
 - pango-0.13.8.0 (lib:pango) (requires build)
 - gio-0.13.8.0 (lib:gio) (requires build)
 - gtk-0.15.4 (lib:gtk) (requires build)
 - threadscope-0.2.12 (exe:threadscope) (requires build)
Starting     glib-0.13.8.0 (all, legacy fallback)
Starting     cairo-0.13.8.0 (all, legacy fallback)
Building     glib-0.13.8.0 (all, legacy fallback)
Building     cairo-0.13.8.0 (all, legacy fallback)
Installing   glib-0.13.8.0 (all, legacy fallback)
Installing   cairo-0.13.8.0 (all, legacy fallback)
Completed    glib-0.13.8.0 (all, legacy fallback)
Starting     gio-0.13.8.0 (all, legacy fallback)
Completed    cairo-0.13.8.0 (all, legacy fallback)
Starting     pango-0.13.8.0 (all, legacy fallback)
Building     gio-0.13.8.0 (all, legacy fallback)
Building     pango-0.13.8.0 (all, legacy fallback)
Installing   pango-0.13.8.0 (all, legacy fallback)
Installing   gio-0.13.8.0 (all, legacy fallback)
Completed    pango-0.13.8.0 (all, legacy fallback)
Completed    gio-0.13.8.0 (all, legacy fallback)
Starting     gtk-0.15.4 (all, legacy fallback)
Building     gtk-0.15.4 (all, legacy fallback)
Installing   gtk-0.15.4 (all, legacy fallback)
Completed    gtk-0.15.4 (all, legacy fallback)
Starting     threadscope-0.2.12 (all, legacy fallback)
Building     threadscope-0.2.12 (all, legacy fallback)
Installing   threadscope-0.2.12 (all, legacy fallback)
Completed    threadscope-0.2.12 (all, legacy fallback)
maoe commented 4 years ago

@AndreasPK Thanks for checking. Closing the issue.

@Twonki Please file a new issue if you still have the build issue.