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

haddock-packages fixes #9213

Merged
merged 4 commits into from
Aug 27, 2023
Merged

haddock-packages fixes #9213

merged 4 commits into from
Aug 27, 2023

Conversation

coot
Copy link
Collaborator

@coot coot commented Aug 27, 2023

Backport for 3.10.2.0

Cherry-picked commits from #8919.

@Mikolaj I asked in another PR but didn't got an answer if this will be accepted; I took a risk and created this PR.

This patch fixes a bug where a sublibrary overwrites a library
directory.  This leads to overwriting `*.haddock` files, which results
in missing entries in various indexes (e.g. the html index,
quicksearch).
@coot coot requested review from Kleidukos and Mikolaj August 27, 2023 09:48
@Kleidukos
Copy link
Member

@coot You didn't get a notification here? #9088 (comment)

@coot
Copy link
Collaborator Author

coot commented Aug 27, 2023

@Kleidukos it was here.

@Kleidukos
Copy link
Member

@coot yes sorry, I meant to ping you there to show you that it was quite hard to get this fix backported. But perhaps this PR will be more lucky! :)

@coot coot force-pushed the coot/haddock-package-fixes-3.10 branch from 21b4ff4 to e0f6a5f Compare August 27, 2023 13:32
@coot
Copy link
Collaborator Author

coot commented Aug 27, 2023

Yes, it wasn't easy because of the style changes that got in the way 😁.

@Kleidukos
Copy link
Member

@coot looks like we're not escaping this problem: https://github.com/haskell/cabal/actions/runs/5991249840/job/16249404279?pr=9213

This patch makes `haddock-project` use `--local` option by default.
Since its the default, it is removed. Also `--gen-index`,
`--gen-contents`, `--hyperlinked-source` and `--quickjump` are removed
since they are always turned on.

Added a haddock-project test.
@coot coot force-pushed the coot/haddock-package-fixes-3.10 branch from e0f6a5f to e23e212 Compare August 27, 2023 15:57
@coot
Copy link
Collaborator Author

coot commented Aug 27, 2023

It should be fixed now, I updated pyyaml to a newer version.

@coot coot marked this pull request as ready for review August 27, 2023 18:59
@Kleidukos
Copy link
Member

@coot It seems to me that the Whitespace check has failed, would you mind fixing that one? I'll merge your PR once my plane lands. :)

`haddock-project` command need to build the project so that haddocks of
the dependencies are available in the store.

Fixes #8958.
@coot coot force-pushed the coot/haddock-package-fixes-3.10 branch from 316f077 to e720627 Compare August 27, 2023 21:43
@Kleidukos Kleidukos self-assigned this Aug 27, 2023
@Kleidukos Kleidukos added squash+merge me Tell Mergify Bot to squash-merge merge delay passed Applied (usually by Mergify) when PR approved and received no updates for 2 days labels Aug 27, 2023
@Kleidukos
Copy link
Member

@coot Dziękuję bardzo!

@Kleidukos Kleidukos merged commit 459c75e into 3.10 Aug 27, 2023
39 checks passed
@Kleidukos Kleidukos deleted the coot/haddock-package-fixes-3.10 branch August 27, 2023 23:38
@Mikolaj
Copy link
Member

Mikolaj commented Aug 28, 2023

@Mikolaj I asked in another PR but didn't got an answer if this will be accepted; I took a risk and created this PR.

Good call. Given the size, though, I'd test it especially hard in the alpha release and, if things don't play out, we can always revert before the release.

@coot
Copy link
Collaborator Author

coot commented Aug 28, 2023

I tested cabal hackage-project command manually. I will check it on a larger project too.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
merge delay passed Applied (usually by Mergify) when PR approved and received no updates for 2 days squash+merge me Tell Mergify Bot to squash-merge
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants