Skip to content
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

mtl-2.3 dropped ExceptT #117

Closed
andreasabel opened this issue May 8, 2022 · 15 comments · Fixed by #121
Closed

mtl-2.3 dropped ExceptT #117

andreasabel opened this issue May 8, 2022 · 15 comments · Fixed by #121

Comments

@andreasabel
Copy link
Member

Apparently, mtl-2.3 dropped ExceptT, see e.g.:

This is a bit surprising, as e.g. it has ReaderT and more of that kind: WriterT, RWST, IdentityT ...

Note that this drop is inconsistent with the documentation of mtl-2.3. E.g. the following example now produces a scope error:

The changelog also does not mention this:

So maybe ExceptT was dropped on error?

(Let me add that I am surprised that this release came without a RC...)

@Bodigrim
Copy link

Bodigrim commented May 8, 2022

ExceptT was dropped in bfddbe8 (merged in #108) with the commit message "Remove some re-exports, raise minimum GHC to 8.6, remove unneeded CPP". While ExceptT is a re-export from transformers indeed, every other entity from transformers such as ReaderT, WriterT, etc., has survived, and AFAIR only re-exports from base such as Control.Monad were planned for removal.

@kozross
Copy link
Collaborator

kozross commented May 8, 2022

@Bodigrim and @andreasabel - you are absolutely right, this was a mistake on my part. I will send a PR today remedying this. Sorry that I missed it.

@andreasabel
Copy link
Member Author

andreasabel commented May 8, 2022

I observe that mtl does not have a testsuite. Having tests could prevent such mistakes.
For a start, examples from the documentation (such as the one I refer to above) could be added to the testsuite.

Historic note: The release of mtl-2.1 was botched, read at agda/agda@8ce5eb0 (typos included), and this blunder could have been prevented by the simplest test suite trying out the State monad. @ekmett compensated me for may 1.5 day bug hunt in Agda with a beer, but apparently, did not see the necessity to add a test suite...

@ekmett
Copy link
Member

ekmett commented May 8, 2022

It seems another beer is at least long overdue. Test suites are on @kosross, however. ;)

@Bodigrim
Copy link

Bodigrim commented May 8, 2022

@kozross FWIW I beg you not to rush: take your time before the next release, upload a package candidate first, gather user's feedback. There is no urgency to resolve this issue today.

@andreasabel
Copy link
Member Author

I agree with @Bodigrim. There is no urgency now, as the problem in mtl-2.3 can be worked around by importing from Control.Monad.Trans.Except.

If you want, @kozross, you can deprecate mtl-2.3 on hackage: https://hackage.haskell.org/package/mtl/preferred/edit
(I just deprecated 2.1 there now --- it hadn't been deprecated...)

@kozross
Copy link
Collaborator

kozross commented May 8, 2022

@andreasabel and @Bodigrim - I agree, rushing isn't a good idea. However, at least in the repo, we should fix this as soon as is reasonable. I feel pretty responsible here, and the fix isn't hard.

As for tests: yes, I agree 100%. I will probably add some; in truth, this is a niche I'm fairly familiar with, so if anyone is suited to do this, it's me.

@sjakobi
Copy link
Member

sjakobi commented May 8, 2022

@kozross, @emilypi Could you possibly follow up on the announcements for mtl-2.3 and say that there will be another release that restores the presence of ExceptT?

@Abastro
Copy link

Abastro commented May 9, 2022

Ouch, got bitten by this. Mistakes could even sneak into mtl I guess.
Is there no way to mark beta release in PVP?

@andreasabel
Copy link
Member Author

Is there no way to mark beta release in PVP?

No. (Maybe there used to be something.) The tool to test releases are release candidates. See, e.g., https://discourse.haskell.org/t/ann-release-candidate-for-mtl-2-3/3687 and #86 (comment).

@Abastro
Copy link

Abastro commented May 9, 2022

Yea, wondering if this could be avoided in the future by using some kind of beta branch, sounds like it would be hard.

@andreasabel
Copy link
Member Author

Concerning tests: just released tasty-1.4.2.3 does not depend on mtl anymore, so it can be used for a testsuite. (Thanks to @Bodigrim.)

@sjakobi
Copy link
Member

sjakobi commented May 11, 2022

What's the timeline for a release containing the fix (#121)?

The current situation is blocking the migration to mtl-2.3 because it's unclear whether packages that fail to build (in part) due to this issue should wait for a fixed release or not. haskell-tls/hs-certificate#129 is an example.

EDIT: texmath also fails to build due to this issue.

@emilypi
Copy link
Member

emilypi commented May 11, 2022

@kozross and I will review and get something out by EOW. There are a few fiddly bits that need sorting out with the docs.

@andreasabel
Copy link
Member Author

If you want, @kozross, you can deprecate mtl-2.3 on hackage

I am worried about the spread of the wildfire, and took action here in my role as Hackage Trustee. I deprecated 2.3. https://hackage.haskell.org/package/mtl/preferred

You can undo this at any time, and please do so if you see adversary effects of the deprecation of 2.3.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants