Typo in gs2_main.fpp prevent build using WITH_EIG=on

Issue #2 resolved
Stephen Biggs-Fox created an issue

(NB: Copied from gs2_test_migrate)

There is a typo in gs2_main.fpp, line 1414, with an extra trailing bracket, i.e. it says this

               timers%eigval(1)/60.,timers%eigval(1)/timers%total(1))

but should be

               timers%eigval(1)/60.,timers%eigval(1)/timers%total(1)

so when you try to build using WITH_EIG=on you get:

gs2_main.f90(1322): error #5276: Unbalanced parentheses
               timers%eigval(1)/60.,timers%eigval(1)/timers%total(1))
--------------------------------------------------------------------^

This was introduced in svn commit r4308.

I think the fix is to simply delete the extra close bracket at the end of the line - works for me on Marconi.

However, with the move to git imminent, I'm not about to set up SVN access. Either someone else can fix it now or I can fix it next week once git access is ready.

Comments (15)

  1. Stephen Biggs-Fox reporter

    (NB: Comment from Joseph Parker copied from gs2_test_migrate)

    Thanks! That fix looks good to me - could you make a PR to master in the new repo?

  2. David Dickinson

    Interesting -- the status of the issue was immediately changed on push even though it hasn't been merged yet. I'll see if I can change this so it only gets resolved once the branch is merged to master/next.

  3. Stephen Biggs-Fox reporter
    • changed status to open

    Re-open as not resolved until merged. Change status manually for now until automatic system is in place.

  4. David Dickinson

    From my initial search it looks like this might not be possible -- we should probably save "fixes" etc. for the PR description and just use the commit message to describe the code changes (perhaps linking to the issue).

  5. Stephen Biggs-Fox reporter

    I'm not sure what you mean by "we should probably save "fixes" etc. for the PR description and just use the commit message to describe the code changes (perhaps linking to the issue)."

    But if it's not possible, then maybe we are misinterpreting the meaning of the status "resolved". Maybe "resolved" means that it's fixed and ready for review/merging and the status gets changed to "closed" after the merge. This allows developers to filter on "open" issues to find something to fix and reviewers to filter on "resolved" to find stuff to review and then "closed" items are excluded from both.

  6. David Dickinson

    @steve_biggs Good point -- it was resolved, not closed. (Of course the decision that a bug is resolved may vary between developers!).

    I just meant something like "Fixes #2" should be saved for the PR description rather than the commit message. That might have been what you've already done.

  7. David Dickinson

    I should note that the default when landing on the issues page is to only show open issues -- so resolved issues will be hidden by default (probably fine but worth noting).

  8. Stephen Biggs-Fox reporter

    No, I put "fixes Issue #2" in the commit message. This is a good idea (and one that should be included in the CONTRIBUTING document) because bitbucket then automatically creates a link to the issue when viewing the commit message online. Therefore, if someone is browsing the commit history separate from the issue tracker, they can see that a commit fixes a particular issue (this is true even without the automatic link so is useful offline too), and they get a free link to the issue.

  9. David Dickinson

    It can be helpful, but of course I wouldn't expect most bugs to be fixed with a single commit (so dangerous in this case to say a single commit fixes the issue as actually need to apply several commits to get fix) -- to get the link can say something like work towards issue #2.

  10. Stephen Biggs-Fox reporter

    Fair enough, yes, I agree - reference the issue to get the link but without saying that it "fixes" it because it does not necessarily do so but rather "work towards" or "in relation to" or similar.

  11. Log in to comment