Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

EclipseFP/OSX: Unpopulated Outline Window

Help
2012-02-02
2012-12-06
  • Michael Jones
    Michael Jones
    2012-02-02

    Once again, my apologies for not doing a thread-per-issue. In a previous thread I said:

    Okay, found another bug.  If I run the plugin, and Eclipse comes up, and I have no haskell source files open, and then I open one of them, the Outline window doesn't get populated.  Hoogle still behaves, so scion-browser is alive, but the Outline window is blank.  (This in turn means that breakpoints can't be set and get locked out, as before when scion-browser's version wasn't reporting).

    On the other hand, if I then leave that source file open, close Eclipse, and reopen it, the source file is already open and waiting for me, *and* the Outline window is populated, and I can set breakpoints.  If at this point I open a *different* source file in the same project, it suffers from a blank outline window, and I can't set breakpoints in that source file (but I can still set breakpoints in the first).

    If I then close and reopen the source file that worked in the Outline window, it stops providing outline again.

    Alright, so I guess that boils down to:  When a source file is opened for the first time *after* the plugin has loaded, the outline window is never populated.

    Another race condition perhaps?  Or a failure to re-populate the outline window on the source files being opened?

    To which your reply was:

    jpmoresmau

    2012-02-01 23:31:26 PST

    Can you please start new threads for new issues? It's not manageable to have tens of different questions in the same thread. Then for your last question, it's obvious it works most of the time for most of the people. How would I be able to work on buildwrapper and scion-browser if I had to restart my Eclipse every time I open a new file?

     
  • Michael Jones
    Michael Jones
    2012-02-02

    Well, I understand that most people aren't having these problems.  I can only report what I'm finding.  Documents already opened as the plugin starts seem to have their Outlines populated, whereas newly opened windows don't.  Its quite peculiar. 

    I shall try to take a look at what happens as a new window is opened to see if I can find out what's going on.

    I did a fresh git clone yesterday to make sure I wasn't hauling around bad 'experiments', so I *should* be clean.

    Once again, thanks for your attention.

     
  • JP Moresmau
    JP Moresmau
    2012-02-02

    There is no link  between scion-browser and the outline. The outline is populated by buildwrapper. Turn on the debug mode for buildwrapper in the preferences and check in the console for your projects.
    There is also no link between this and the breakpoints. The breakpoints are set by Eclipse. The outline could not work and you could still set breakpoints or start a GHCi session.
    Do you see the syntax highlight? Are you sure the file is opened in the Haskell editor? what happens when you modify the file?

     
  • JP Moresmau
    JP Moresmau
    2012-02-02

    Actually, you're right. It may happen: for some reason the outline result is obtained before the init method of the editor is actually called… I've never seen that before… My guess is that the enhancements in performance make this more likely to happen, whereas before we would do a GHC build before the outline, we now calculate the outline first.
    I have pushed a fix to github if you work from source. As yesterday's release was a rush job to out everything back in sync we will probably find more of these, so your input is precious! Thanks!

     
  • Michael Jones
    Michael Jones
    2012-02-02

    My apologies for my (apparently) repeated misunderstanding of how the plugin works.  I'm struggling to catch up to where you are, and it's a fascinating exercise, so I appreciate the opportunity to help and be taken seriously. :)

    I am repeatedly working from source, so that I might help find these issues faster.  I like this plugin very much from what I've seen so far, and I want to make sure my OSX brethren don't hit a wall. ;)  Also I want to further experimentation in haskell, which is helped by good tools.

    Anyway.  My motivations aside, I will grab the latest source, and report back about this specific issue here.

    I'm still having trouble 'exporting' the plugin to a module that Eclipse can use without the source.   I'll post that issue in the link below.

    https://sourceforge.net/projects/eclipsefp/forums/forum/371922/topic/4993608

     
  • Michael Jones
    Michael Jones
    2012-02-03

    Okay, so I had a toolchain explosion that embarrassingly I think I caused (lost scion-browser).  In my attempts to rebuild it, it started segfaulting, although I'm sure I built my libraries all cleanly.  So after a day of screwing with that , I upgraded to 7.4.1 since it just got released, and it seems to build most packages easily.  But obviously something in GHC changed so buildwrapper doesn't build anymore.  So either i have to find a way to go back to 7.2.1, or I patch buildwrapper for 7.4.1.

    Anyway, that's just background as to why I'm delayed in reporting.  Before everything went boom, I verified that this problem has gone away, in my limited testing anyway.  So thank you for your attention to this problem!  I'm going to keep hammering at this.

    I'll post about the buildwrapper / 7.4.1 issue in another post: https://sourceforge.net/projects/eclipsefp/forums/forum/371922/topic/4996382

     
  • Michael Jones
    Michael Jones
    2012-02-05

    Okay, this isn't *quite* fixed.

    We have a much weaker problem now.  On creation of  a brand new Haskell project in the workspace, it sets up all the files by default including Main.hs.  When I double-click on Main.hs, it opens as I'd expect in the editor window.  however, the Outline window isn't populated.

    With buildwrapper debugging output turned on, I got:

    configuring because setup_config not present

    build-wrapper-json:[,]
    configuring because setup_config not present

    build-wrapper-json:[{"fps":,"r":false},]
    configuring because setup_config not present

    build-wrapper-json:[{"fps":,"r":false},]
    configuring because setup_config not present

    build-wrapper-json:[,]
    configuring because setup_config not present

    configuring because setup_config not present

    buildwrapper: /Users/michaeljones/Documents/Programming/Haskell/runtime-EclipseApplication/TestProject2/.dist-buildwrapper/src/Main.hs: openBinaryFile: does not exist (No such file or directory)
    build-wrapper-json:"src/Main.hs"
    build-wrapper-json:[false,]
    build-wrapper-json:[[{"K":},{"IC":},{"K":},{"IV":},{"S":},{"IC":},{"SS":},{"SS":},{"IV":},{"S":},{"IV":}],]

    On closing Main.hs, and reopening it, then I get the Outline window populated.

    I haven't tested this on something more elaborate like importing an existing project with lots of files, but I thought I'd bring this up.

    I'm not sure if this qualifies as a brand new bug.  If so, I can move it.

     
  • JP Moresmau
    JP Moresmau
    2012-02-06

    Can't reproduce on windows, so my guess would be another file path issue on MacOs/Unix. The easiest thing first is to run the buildwrapper tests on your machine. Just run cabal install -enable-tests and cabal test. We can then try to fix the issues in buildwrapper before thinking about EclipseFP itself.

     
  • Michael Jones
    Michael Jones
    2012-02-07

    Okay, now I'm fighting with cabal.  Of course I have the cabal-install from 7.4.1 lingering around, and the build-test gives me errors when I run it because of that, despite blowing away my ~/.cabal folder and my ~/.ghc folder and reinstalling 7.2.2.  The error is:

    :"buildwrapper: user error (You need to re-run the 'configure' command. The version of Cabal being used has changed (was Cabal-1.14.0, now Cabal-1.12.0). Additionally the compiler is different (was ghc-7.4, now ghc-7.2) which is probably the cause of the problem.)\n"
    expected: ExitSuccess
    but got: ExitFailure 1

    which I expect is somehow normal for the cabal test facility?  Anyway.  I'll run the test suite as soon as I can make my cabal the one compatible with 7.2.2.

     
  • Michael Jones
    Michael Jones
    2012-02-07

    Okay, I got the buildwrapper test to run, and it passed 18 and failed 13.  The output log file is about 43k, so I'm rather reluctant to paste it in this forum.

    Got a place I can send it to?  Or is there something you want me to extract?

     
  • JP Moresmau
    JP Moresmau
    2012-02-07

    Just email it to me (jp _at_ moresmau.fr). I'm not sure I can do much without a MacOs install to test, but since that test-suite always pass 100% under windows there are obviously still bugs in there.

     
  • Michael Jones
    Michael Jones
    2012-02-07

    Sent.