-
Notifications
You must be signed in to change notification settings - Fork 697
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
Rebase of #5370 (fix for #4683) #7409
Conversation
Yay, I didn't follow the original issue not PR, but great job rescuing this work. BTW, my commits are now merged to master so you can rebase and they should vanish from your PR. I will then start the CI. Any idea who would be the best pair of reviewers? |
caa65b3
to
1955326
Compare
@Mikolaj rebased. I have no idea about potential reviewers though :-( Is there anything like code owners? The patch has to do with |
@Mikolaj it seems to have failed, yes. Sorry! I'll look into it later today. (At least, it built for me before the latest rebase) |
@Mikolaj this should fix it. |
Oh no, test suite is still not OK. Will check it out later this week. |
@ulysses4ever: let me know if I can help. |
@Mikolaj indeed, I got stuck a bit, thank you for suggesting. I looked into the CI failures a bit. What fails seems to be quick-checked tests coming from My current problem, though, is that I don't see docs for how to manually run quick-checked tests. I used cabal-testsuite/README.md before but it doesn't seem to cover quick-checked tests. |
Let's try to unravel this together. I've run
on your PR branch and it passes fine. And indeed the failing bit of CI does not mention
and indeed it fails for me, with GHC 9.0.1 (the one that I have ready) substituted for the older GHC and things it couldn't find built:
I guess I'd start by rebasing your branch on newest master (it did fail a couple of weeks ago). Back to you. |
Okay, thanks a lot @Mikolaj for carifying this. I figured simply
is enough, and even better: to get to the actual failing QuickCheck tests faster skipping slow passing tests, the
Another question. Currently A more challenging task would be to preserve the extended policy and fix the tests. There are two ways to do that. Either change the arbitrary instances or use the post processing filter of checking results. I am no big fun of either: first approach looks messy because it propagates the difference between setup checks and component checks deep into test suite; the second one with post processing feels very ad hoc. So, I'm curious what you think about this: would it be fine to shrink the original PR to have cabal only checking base and Cabal on setup dependencies or there's some good reason to have stricter policy there, and therefore hacking into the test suite is justified. |
I can't see any discussion and agreement about turning warnings into errors (and covering all deps) in the original issue. @fgaz: are you aware of any? Given that it's an invention of the PR we are fixing and that it complicates the implementation, I think it's a good idea to go back to the spec from the issue. |
(Just a minor comment: warnings vs errors doesn’t matter for the current test suite failures. What matters is checking bounds on all dependencies instead of just base/Cabal.) |
No. Personally, I'd be in favor of extending the warning (a non-fatal one though) to all dependencies, because of this, but I also think we need some proper discussion before such a change, so I agree on reducing the scope of this pr |
0c0cef3
to
1e15c8f
Compare
@fgaz thanks a lot for chiming in! I agree that extending warnings would be worthwhile, but don't think it makes much sense to have different warning strategies for setup dependencies and component dependencies. How about you? Meanwhile I pushed a boiled down version of checks (only base and Cabal). Locally it passed the tests that used to fail on CI. |
Thanks a lot for the comments @Mikolaj! I hope I addressed them now. |
2e9bf15
to
276fe86
Compare
Just a heads-up: the commit message should be updated during squashing. Or I can do this and force-push (I prefer to have separate commits during code review but after it's done they're no longer relevant). |
@ulysses4ever: is this ready from your POV? |
@Mikolaj yes, that's my feeling. |
@emilypi: would you review? |
@@ -2394,3 +2401,29 @@ isGoodRelativeDirectoryPath = state0 | |||
-- | otherwise -> 4 | |||
-- 6 -> \_ -> 6 -- black hole | |||
-- @ | |||
|
|||
-- TODO: move to Distribution.Version |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why the TODO?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh, great point! In fact there is already such a function there. Fixed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@emilypi maybe you could take a look and say if it's good enough now. 🙏
setup depends are now checked for having upper dependencies. Upper bounds are mandatory for base and Cabal libraries, and are optional (but emit warning) for other libraries. Implicit dependencies are not being checked.
3b561eb
to
bc4ba8e
Compare
@emilypi: would it be possible for you to re-review so that we can move this forward? Thank you! |
@Mikolaj will do |
AppVeyor died in a way I don't understand: https://ci.appveyor.com/project/emilypi/cabal/builds/40523206 Let me update the branch again (master moved since). |
#5370 got really close to fixing #4683 but got stuck on trying to solve the
-any
vs no bounds confusion. Since 3.4,-any
disappeared and took this issue with it. So I thought it's a pity this work is still unmerged.Please include the following checklist in your PR:
Please also shortly describe how you tested your change. Bonus points for added tests!