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

Fix NoSuchElementException in scaladoc #18184

Merged
merged 2 commits into from
Jul 13, 2023
Merged

Conversation

Florian3k
Copy link
Contributor

@Florian3k Florian3k commented Jul 11, 2023

This should fix the error causing recent fails of Nightly Dotty workflow.
However, I don't know why it fails so randomly. We might want to investigate and fix this properly.

Fixes #18143

@@ -33,7 +33,7 @@ object SectionRenderingExtension extends HtmlRenderer.HtmlRendererExtension:
val Section(header, body) = node
val idSuffix = repeatedIds.getOrElseUpdate((c, header.getText), 0)
val ifSuffixStr = if(idSuffix == 0) then "" else idSuffix.toString
repeatedIds.update((c, header.getText), repeatedIds((c, header.getText)) + 1)
repeatedIds.update((c, header.getText), idSuffix + 1)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Those the result of header.getText have a stable hash?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it should, but just to be extra safe I extracted that in the next commit

@nicolasstucki nicolasstucki merged commit f1ca099 into scala:main Jul 13, 2023
17 checks passed
@Kordyjan Kordyjan added this to the 3.4.0 milestone Aug 2, 2023
Kordyjan added a commit that referenced this pull request Dec 8, 2023
Backports #18184 to the LTS branch.

PR submitted by the release tooling.
[skip ci]
@Kordyjan Kordyjan modified the milestones: 3.4.0, 3.3.2 Dec 14, 2023
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 this pull request may close these issues.

Nightly Dotty workflow of 2023-07-05 failed
3 participants