-
Notifications
You must be signed in to change notification settings - Fork 691
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
doctests: switch to the preffered method of calling the tool #8735
Conversation
I really wish |
f023545
to
bd6e880
Compare
Oh Lord, it's failing even locally now. I can swear to god that yesterday it worked just fine... |
You can run |
@andreasabel that's what I ended up doing, yes. The issue is: I need to have it locally to do that, and that's not always convenient (I have many environments...). I much rather I saw the issue in the CI and could fix it manually instead of installing it, if it seems easier to me. |
bd6e880
to
3089f89
Compare
All right, fellas. The new method seems to be more sensitive to GHC version. Seems to work fine now. |
3089f89
to
b4ef067
Compare
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.
Great work!
Maybe the local workflow (Makefile) could be made more robust by having and executing goals for installing doctest
for the current GHC version, and checking for correct doctest
versions. Some ideas in:
e7cd5d7
to
a8488d6
Compare
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.
Thanks a lot!
@andreasabel could you please take another look and comment further or approve? |
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.
Thanks for this great work of research and implementation!
(I know what it takes, as I have spent many days just to get doctest
working on various projects.)
Thanks @andreasabel! I just stood on the shoulders of giants (nomeata and wismill, in this case). By the way, if you have a spare winter evening, I'm sure you'll enjoy this recent Haskell Discourse thread about various ways of doctesting. (Most of it you probably know by now, though) |
which is `cabal repl --with-ghc=doctest`. This not only catches up with the current upstream recommendations, but also simplifies the usage: before this change calling doctest required you to set up an environment with QuickCheck available (we used to do it via cabal-env). The new method takes care of it automatically. Also add some docs to fix haskell#8147
a8488d6
to
822d1a7
Compare
@mergify backport 3.10 |
✅ Backports have been created
|
doctests: switch to the preffered method of calling the tool (backport #8735)
which is
cabal repl --with-ghc=doctest
. This not only catches up with the current upstream recommendations, but also simplifies the usage: before this change calling doctest required you to set up an environment with QuickCheck available (we used to do it via cabal-env). The new method takes care of it automatically.Also add some docs to fix #8147
Please include the following checklist in your PR:
Please also shortly describe how you tested your change. Bonus points for added tests!