hackage-server icon indicating copy to clipboard operation
hackage-server copied to clipboard

Accept multi-lib packages with public sublibraries

Open brprice opened this issue 1 year ago • 1 comments

Now that cabal 3.8 has been released and multi-lib packages are no longer experimental, my understanding is that it is planned to update Hackage to accept multi-lib (with publicly visible sublibraries) packages (https://github.com/haskell/hackage-server/issues/852#issuecomment-1153313147). I am opening this issue mostly to have something upstream to track the progress of this.

Some specific questions:

  • Am I correct in thinking this is a planned feature?
  • Any idea on an ETA?
  • What (if anything) can I do to help progress this?
  • Is this blocked by https://github.com/haskell/cabal/issues/5660 (or anything else)?

Links to other tracking issues in the ecosystem:

  • https://github.com/brendanhay/amazonka/issues/671
  • https://github.com/sol/hpack/issues/483

brprice avatar Aug 10 '22 16:08 brprice

This is indeed a planned feature. I think the groundwork is basically laid except for porting hackage server to link against 3.8 and a new deploy. Once that's done, the UX might be a bit rough still, but it should all work at least (and we can improve the display as we go). Hopefully we can do this forward port and deploy in the next couple months, following the conclusion of gsoc projects which should also be incorporated into the upcoming deploy.

gbaz avatar Sep 08 '22 17:09 gbaz

I totally thought this was already done! Is my recollection incorrect or is some brave soul updating hackage code needed?

cartazio avatar Mar 23 '23 22:03 cartazio

I think it should work now, if anyone has a multilib package to upload.

gbaz avatar Mar 24 '23 01:03 gbaz

Ok cool! Are there any on hackage yet ? I’m curious what the ui looks like

cartazio avatar Mar 24 '23 17:03 cartazio

closing as done.

gbaz avatar May 14 '23 01:05 gbaz

I'm also curious as to whether there are any examples in the wild. I think a number of us are keen to try this out but anxious not to mess up our packages accidentally, so it would be great to see an example which we could poke and check it seems to work okay!

michaelpj avatar May 15 '23 10:05 michaelpj

From a quick index grep, there is currently no such package on hackage

edit: but you can experiment by uploading candidates

fgaz avatar May 15 '23 12:05 fgaz

i may have 1-2 experiments lying around i can try in the near future once i clean them up

On Mon, May 15, 2023 at 8:46 AM Francesco Gazzetta @.***> wrote:

From a quick index grep, there is currently no such package on hackage

— Reply to this email directly, view it on GitHub https://github.com/haskell/hackage-server/issues/1119#issuecomment-1547795873, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAABBQQWVLNVBZMBZGJGSN3XGIQSLANCNFSM56FFGKUQ . You are receiving this because you commented.Message ID: @.***>

cartazio avatar May 15 '23 13:05 cartazio

I'm also curious as to whether there are any examples in the wild. I think a number of us are keen to try this out but anxious not to mess up our packages accidentally, so it would be great to see an example which we could poke and check it seems to work okay!

We will have one very shortly; no later than this year's Zurihac, I expect.

dhess avatar May 15 '23 15:05 dhess

How is one actually supposed to use this feature? I've run the usual cabal upload --publish $(cabal sdist | tail -n1), but I see no sign of anything other than the main library on Hackage. The others are present in the sdist tarball, and in fact were even before I set visibility: public for them, since they are depended on by the main lib. But none of their modules appear in the Hackage module list.

georgefst avatar Jun 29 '23 23:06 georgefst

Upload is allowed, but the hackage UI isn't there yet. You can still use the public libraries in other cabal packages though

fgaz avatar Jun 30 '23 04:06 fgaz

Upload is allowed, but the hackage UI isn't there yet.

Ah, yes, I now see that that's tracked in #1218.

You can still use the public libraries in other cabal packages though

Can confirm this does work! At least when adding to build-depends in a .cabal file (install --lib has issues: https://github.com/haskell/cabal/issues/9074).

georgefst avatar Jun 30 '23 14:06 georgefst