-
Notifications
You must be signed in to change notification settings - Fork 700
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable per-component builds when coverage is enabled #4902
Conversation
i guess this would be fine (even if its a shame that theres that tension atm) i'm ok with the coverage checking we (should do) being under a different flag / build way than component stuff .... which isn't terribly documented at the moment as far as I can tell? aside from here? |
I didn't mean to imply this is a temporary situation |
It does seem like you'd have to basically figure out how to do coverage across packages to solve this problem in general. @ttuegel is another possibility to only disable per-component on the "top" package, not all of them? (Maybe this patch does that already) |
This should only disable per-component builds on the package(s) that have coverage enabled. However, because command-line arguments are currently broken, passing |
@ezyang |
Yes, this should be possible. TBH, I don't know what the idiomatic way to do this is, but reading |
The new test seems to be failing on CI. |
Yeah, in the test I added, I didn't check that GHC ships with shared libraries before testing. I thought that was a given; obviously not! 😃 |
@cartazio |
9995d90
to
84a07d8
Compare
You have my gratitude
…On Mon, Nov 27, 2017 at 9:21 AM Thomas Tuegel ***@***.***> wrote:
@cartazio <https://github.com/cartazio>
Once I fix the test cases, I'm going to merge this and backport to
cabal-install-2.0 because I don't have an ETA on the proper fix; hopefully
this will not make it into cabal-install-2.2, but if it does then at least
program coverage will work!
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4902 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAQwkPosqi6lQZSBspCB0B9Z2z-XzEoks5s6sVsgaJpZM4QnyID>
.
|
For reasons currently unbeknownst to me, coverage is still broken with GHC 7.8 and GHC 7.10, but not with more recent versions. I suspect something has changed about how GHC handles HPC search paths, but I'm not sure yet. |
Hrmmm. That no good.
Happily that doesn’t affect me at all though :)
(I have this quaint belief that it’s very hard to get bug fixes into old
ghc releases so I should always use the current major version. )
…On Mon, Nov 27, 2017 at 6:20 PM Thomas Tuegel ***@***.***> wrote:
For reasons currently unbeknownst to me, coverage is still broken with GHC
7.8 and GHC 7.10, but not with more recent versions. I suspect something
has changed about how GHC handles HPC search paths, but I'm not sure yet.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4902 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAQwq2UyULLNkZUKJF-qjp93oSfsLmQks5s60PBgaJpZM4QnyID>
.
|
I agree, nobody should use or support old GHCs, but here we are. My fear is that the problem actually persists with GHC 8.x but the test case doesn't catch it, so I won't be satisfied until it works with GHC 7.x also. |
Ok. If there’s any ways I can help test on ghc 8 let me known
…On Tue, Nov 28, 2017 at 8:23 AM Thomas Tuegel ***@***.***> wrote:
I have this quaint belief that it’s very hard to get bug fixes into old
ghc releases so I should always use the current major version.
I agree, nobody should use or support old GHCs, but here we are.
My fear is that the problem actually persists with GHC 8.x but the test
case doesn't catch it, so I won't be satisfied until it works with GHC 7.x
also.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4902 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAQwiQovG8Dr0tF9mTxB94uk5421myOks5s7AlfgaJpZM4QnyID>
.
|
84a07d8
to
49704f6
Compare
The Travis failures are
but I don't have the permissions to restart the failed tests. |
Hmm, I thought you were already a member of the haskell/cabal group. @hvr,
can you please add @ttuegel?
…On 29 Nov 2017 17:14, "Thomas Tuegel" ***@***.***> wrote:
The Travis failures are
1. A timeout, and
2. an unrelated test failure,
but I don't have the permissions to restart the failed tests.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#4902 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAC5TzVTbvo1HeaNrhazAb_w70aswL3Aks5s7ZD1gaJpZM4QnyID>
.
|
Actually I was; I had gotten signed out of Travis and didn't notice. I can only restart the builds for |
@ezyang Can we add everyone in the |
The timeout problem I thought was transient is not. Between the new tests I added, GHC 7.10 being slow, and the Travis macOS machines being slow, that build consistently fails. Is there a preferred solution for slow tests? |
@23Skidoo I'm happy to but we have to decide what to do; haskell-pushbot is a user, not an org. One thing we could try is to move the |
The "build is too long" situation is a bit of a problem. So, the reason we are running tests in the "build" (and not the spillover job) is because all of these tests require the Cabal library to be used when a test script is run, but all of the compiled libraries are like 5G and are too big to put in the cabal-binaries repo. One way we might be able to work around this is to somehow add a mode to cabal-tests where we compile in all of the test scripts into the test binary, so we can go ahead and run it directly. But this requires some nontrivial dev work. Another possibility is to speed up the build. We've probably gotten most of the low hanging fruit but there might still be some possibilities. BTW osx-7.8.4 build is a legit failure, not timeout. |
Creating the test program coverage report requires the test runner to know the build directory for the library component. If per-component builds are enabled, this is not possible because the library is not in-scope at the same time as the test component. The only apparent solution that does not require rethinking per-component builds entirely is to disable it when coverage is enabled. Resolves: haskell#4798
49704f6
to
2592dc6
Compare
Unfortunately, removing a few redundant tests did not speed up the build enough with GHC 7.8 and 7.10 (the slower versions). I fear this PR is DOA unless we can find a solution to the build time problem. |
I need to finally sit down and finish #4231, that should help macOS build times a bit. Maybe we can also skip haddock and sdist steps on macOS. Here is a table of build steps performed by one of the failed jobs ordered by the time they take:
A bit weird that |
Is it actually necessary to run the package tests with |
I think that the |
Yes. Some of those tests are |
You wouldn't have to search replace them all; just change the logic in |
It wouldn't really be I think I will just add a flag to |
Well, the intent for these tests is that they could be run for setup or cabal... not that we actually do ;) Your plan sounds great. |
My plan was to only run the |
@ezyang Do you think it'd be possible to run more of time-consuming tests mentioned in #4902 (comment) on edit: Apparently, it's non-trivial, see #4902 (comment). See also #4462. |
Since we are already caching EDIT: This would require some non-trivial fiddling with Travis' build stages feature. |
OK, I think I have a pretty good idea of how to split up the Travis jobs so they don't time-out. I'll have a PR in a day or so. |
@ttuegel If you want to experiment with build stages, you may want to take a look at my previous attempt (#4560 and #4556 (comment)). If you won't be able to work around the macOS timeout issue, I can see the following paths forward: a) Merge your patch into the (soon-to-be-created) 2.2 branch, but without the test. |
i think we have at least one dedicated mac mini that @bgamari and @davean
can figure out how to add mac testing for cabal support to
…On Wed, Dec 20, 2017 at 1:01 PM, Mikhail Glushenkov < ***@***.***> wrote:
@ttuegel <https://github.com/ttuegel> If you want to experiment with
build stages, you may want to take a look at my previous attempt (#4560
<#4560> and #4556 (comment)
<#4556 (comment)>).
If you won't be able to work around the macOS timeout issue, I can see the
following paths forward:
a) Merge your patch into the (soon-to-be-created) 2.2 branch, but without
the test.
b) For 2.4/3.0, move macOS builds away from Travis -- not sure where yet,
maybe GHC HQ will let us share their CircleCI account. If there's no
suitable free service, we'll have to find money/sponsorship. I'm willing to
invest time into configuring and administering an alternative macOS build
bot.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#4902 (comment)>, or mute
the thread
<https://github.com/notifications/unsubscribe-auth/AAAQwvhu67bEKRRcxCLo0eOavh6tTUGbks5tCUuAgaJpZM4QnyID>
.
|
This really should be in 2.2. One option (nuclear) is to temporarily mark the slowest macOS configurations |
We clearly don't have the bandwidth at the moment to fix the OS X build situation, so I vote for nuking the slow test. |
We can add the code for the test, but disable it and add a TODO. |
How do I disable |
Good question. We still want to compile it (to prevent bit-rotting), but mark it as disabled for now. I believe that this is not supported right now, so we should add this feature to the test runner first. I may have time to look into it next week. |
You can skip tests by calling |
Closing in favour of #5004. |
Thank you! |
Disable per-component build when program coverage enabled
Creating the test program coverage report requires the test runner to know the
build directory for the library component. If per-component builds are enabled,
this is not possible because the library is not in-scope at the same time as the
test component. The only apparent solution that does not require rethinking
per-component builds entirely is to disable it when coverage is enabled.
Resolves: #4798
[ci skip]
is used to avoid triggering the build bots.cc @cartazio @cj285