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

Build breakage due to mtl upper bound #64

Closed
snoyberg opened this Issue May 7, 2014 · 11 comments

Comments

Projects
None yet
5 participants
@snoyberg
Contributor

snoyberg commented May 7, 2014

Reproed on GHC 7.4.2, 7.6.3, 7.8.2. Using cabal-install 1.16 for the first two, 1.18 when using GHC 7.8.

Start with a clean package environment, then run:

cabal install cabal-install-1.16.0.2 --dry-run

Due to inconsistent upper bounds on transformers, the build plan selects HTTP-4000.0.7. At least on GHC 7.4.2, this package install ultimately fails with:

[ 7 of 15] Compiling Network.BufferType ( Network/BufferType.hs, dist/build/Network/BufferType.o )

Network/BufferType.hs:57:10:
    Illegal instance declaration for `BufferType String'
      (All instance types must be of the form (T a1 ... an)
       where a1 ... an are *distinct type variables*,
       and each type variable appears at most once in the instance head.
       Use -XFlexibleInstances if you want to disable this.)
    In the instance declaration for `BufferType String'
Failed to install HTTP-4000.0.7
cabal: Error: some packages failed to install:
HTTP-4000.0.7 failed during the building phase. The exception was:
ExitFailure 1
cabal-install-1.16.0.2 depends on HTTP-4000.0.7 which failed to install.

This is the exact same issue as #55. This problem is likely to cause wide-spread breakage until a new version of HTTP is released which is compatible with transformers 0.4.

@snoyberg snoyberg changed the title from Build breakage due to transformers upper bound to Build breakage due to mtl upper bound May 7, 2014

snoyberg added a commit to snoyberg/HTTP that referenced this issue May 7, 2014

@mightybyte

This comment has been minimized.

Show comment
Hide comment
@mightybyte

mightybyte May 8, 2014

And like issue #55, the real cause of this problem is the lack of upper bounds on HTTP-4000.0.7, not the presence of upper bounds on the current version of HTTP.

And like issue #55, the real cause of this problem is the lack of upper bounds on HTTP-4000.0.7, not the presence of upper bounds on the current version of HTTP.

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg May 8, 2014

Contributor

If you want to call that the real cause, that's fine. What's the real solution then?

Contributor

snoyberg commented May 8, 2014

If you want to call that the real cause, that's fine. What's the real solution then?

@hsenag

This comment has been minimized.

Show comment
Hide comment
@hsenag

hsenag May 8, 2014

Member

I've fixed the mtl dep.

Is there anything more I can do about this general problem with the old versions in the HTTP package? Otherwise I guess the remaining issue is one for cabal/hackage, not HTTP.

Pinging @tibbe - do we understand why the version preference you added before isn't helping in this situation?

Member

hsenag commented May 8, 2014

I've fixed the mtl dep.

Is there anything more I can do about this general problem with the old versions in the HTTP package? Otherwise I guess the remaining issue is one for cabal/hackage, not HTTP.

Pinging @tibbe - do we understand why the version preference you added before isn't helping in this situation?

@tibbe

This comment has been minimized.

Show comment
Hide comment
@tibbe

tibbe May 8, 2014

Member

I filed a bug against cabal re the preference issue. I think it's due to a
misunderstanding of the desired behavior when the preference support was
implemented.

As for old http package version, you could release patched versions of old
http major releases. This would help a tiny bit as cabal has a soft
preference for newer version. However, today there exists no real mechanism
to fix build breakages due to omitting upper bound.
On May 8, 2014 8:55 AM, "Ganesh Sittampalam" notifications@github.com
wrote:

I've fixed the mtl dep.

Is there anything more I can do about this general problem with the old
versions in the HTTP package? Otherwise I guess the remaining issue is one
for cabal/hackage, not HTTP.

Pinging @tibbe https://github.com/tibbe - do we understand why the
version preference you added before isn't helping in this situation?


Reply to this email directly or view it on GitHubhttps://github.com/haskell/HTTP/issues/64#issuecomment-42518631
.

Member

tibbe commented May 8, 2014

I filed a bug against cabal re the preference issue. I think it's due to a
misunderstanding of the desired behavior when the preference support was
implemented.

As for old http package version, you could release patched versions of old
http major releases. This would help a tiny bit as cabal has a soft
preference for newer version. However, today there exists no real mechanism
to fix build breakages due to omitting upper bound.
On May 8, 2014 8:55 AM, "Ganesh Sittampalam" notifications@github.com
wrote:

I've fixed the mtl dep.

Is there anything more I can do about this general problem with the old
versions in the HTTP package? Otherwise I guess the remaining issue is one
for cabal/hackage, not HTTP.

Pinging @tibbe https://github.com/tibbe - do we understand why the
version preference you added before isn't helping in this situation?


Reply to this email directly or view it on GitHubhttps://github.com/haskell/HTTP/issues/64#issuecomment-42518631
.

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg May 8, 2014

Contributor

@hsenag Thanks for getting the new version onto Hackage.

The reason the version preference doesn't work is documented here: haskell/cabal#1792. AFAICT, there are no plans to actually address that issue, which seems to mean that for the foreseeable future, every time a major version of an HTTP dependency is released, build plans will immediately start failing.

Contributor

snoyberg commented May 8, 2014

@hsenag Thanks for getting the new version onto Hackage.

The reason the version preference doesn't work is documented here: haskell/cabal#1792. AFAICT, there are no plans to actually address that issue, which seems to mean that for the foreseeable future, every time a major version of an HTTP dependency is released, build plans will immediately start failing.

@hsenag

This comment has been minimized.

Show comment
Hide comment
@hsenag

hsenag May 8, 2014

Member

OK, thanks - sounds like it just needs someone to implement the idea in the thread, so if this continues to cause pain perhaps someone will do that.

I don't think I'm willing to be forever maintaining a 4000.0.7 branch of HTTP to keep up to date with the latest code in dependencies, and I don't really want people to be randomly ending up with that old version.

If I could retrospectively fix the upper bounds on hackage, that would be something that's worth the effort.

Member

hsenag commented May 8, 2014

OK, thanks - sounds like it just needs someone to implement the idea in the thread, so if this continues to cause pain perhaps someone will do that.

I don't think I'm willing to be forever maintaining a 4000.0.7 branch of HTTP to keep up to date with the latest code in dependencies, and I don't really want people to be randomly ending up with that old version.

If I could retrospectively fix the upper bounds on hackage, that would be something that's worth the effort.

@hsenag hsenag closed this May 8, 2014

@snoyberg

This comment has been minimized.

Show comment
Hide comment
@snoyberg

snoyberg May 8, 2014

Contributor

Changing version bounds after-the-fact is not currently supported by Hackage, and I think the reason is because it's unknown how that may cause breakage for others. But specifically adding stricter bounds seems like it's more likely to cause breakage with the current toolset, so I'd be cautious about moving ahead with that.

Contributor

snoyberg commented May 8, 2014

Changing version bounds after-the-fact is not currently supported by Hackage, and I think the reason is because it's unknown how that may cause breakage for others. But specifically adding stricter bounds seems like it's more likely to cause breakage with the current toolset, so I'd be cautious about moving ahead with that.

@hsenag

This comment has been minimized.

Show comment
Hide comment
@hsenag

hsenag May 8, 2014

Member

I guess if it is turned on then it would be because the toolset is thought to support it :-) If we'd had the stricter bounds all along the current situation would be much better.

Member

hsenag commented May 8, 2014

I guess if it is turned on then it would be because the toolset is thought to support it :-) If we'd had the stricter bounds all along the current situation would be much better.

@tibbe

This comment has been minimized.

Show comment
Hide comment
@tibbe

tibbe May 12, 2014

Member

After-the-fact updating of .cabal files (and thus bounds) on Hackage, was implemented by Duncan. Turns out that his implementation had a bug and he hasn't had time to fix it yet.

Member

tibbe commented May 12, 2014

After-the-fact updating of .cabal files (and thus bounds) on Hackage, was implemented by Duncan. Turns out that his implementation had a bug and he hasn't had time to fix it yet.

@snoyberg snoyberg referenced this issue in jcristovao/enclosed-exceptions May 16, 2014

Closed

Transformers upgrade #2

@hvr

This comment has been minimized.

Show comment
Hide comment
@hvr

hvr Aug 23, 2014

Member

Btw, what's keeping us now from fixing up all old HTTP package version's known-to-be-wrong cabal meta-data?

(Fwiw, something similar was done for mtl and template-haskell as soon as after-the-fact updating of .cabal files got enabled, as ancient mtl/template-haskell packages also didn't have upper bounds yet)

Member

hvr commented Aug 23, 2014

Btw, what's keeping us now from fixing up all old HTTP package version's known-to-be-wrong cabal meta-data?

(Fwiw, something similar was done for mtl and template-haskell as soon as after-the-fact updating of .cabal files got enabled, as ancient mtl/template-haskell packages also didn't have upper bounds yet)

@hsenag

This comment has been minimized.

Show comment
Hide comment
@hsenag

hsenag Aug 23, 2014

Member

From my point of view,
(1) Figuring out the correct upper bounds for each release
(2) Deciding what I feel about the after-the-fact-editing, as it does seem a bit evil never mind, if it's in general use anyway and people think it works it's not worth worrying about :-)

Member

hsenag commented Aug 23, 2014

From my point of view,
(1) Figuring out the correct upper bounds for each release
(2) Deciding what I feel about the after-the-fact-editing, as it does seem a bit evil never mind, if it's in general use anyway and people think it works it's not worth worrying about :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment