Skip to content

Upgrade reference compiler to 3.0.1-RC2 #12913

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

Closed
wants to merge 2 commits into from

Conversation

smarter
Copy link
Member

@smarter smarter commented Jun 23, 2021

No description provided.

@smarter
Copy link
Member Author

smarter commented Jun 23, 2021

 Error:  -- Error: /__w/dotty/dotty/library/src/scala/annotation/experimental.scala:14:6 
Error:  14 |class experimental extends StaticAnnotation
Error:     |^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
Error:     |use of @experimental is experimental and therefore may only be used with a nightly or snapshot version of the compiler

@nicolasstucki Did something change in how @experimental is checked between 3.0.0 and 3.0.1-RC2?

@bishabosha
Copy link
Member

bishabosha commented Jun 23, 2021

@nicolasstucki Did something change in how @experimental is checked between 3.0.0 and 3.0.1-RC2?

#12672?

@smarter
Copy link
Member Author

smarter commented Jun 25, 2021

@anatoliykmetyuk Should #12672 be backported to release-3.0.1? As is, the compiler from that branch cannot be used as a reference compiler, so we can't release 3.0.1 without fixing that.

@smarter smarter requested a review from anatoliykmetyuk June 25, 2021 11:22
@smarter smarter added this to the 3.0.1 milestone Jun 25, 2021
@smarter
Copy link
Member Author

smarter commented Jun 29, 2021

Looks like the issue with @experimental doesn't happen when using a nightly as a reference compiler, so hopefully we'll be able to use 3.0.2-RC1 as our reference compiler (and just skip 3.0.1 since using the latest RC is more valuable anyway). However stdlib-sourcelinks-test fails currently:

Error: Test dotty.tools.scaladoc.sourcelinks.RemoteLinksTest.runTest failed: Page 3.0.2-RC1-bin-20210628-10145ff-NIGHTLY/tasty/src/dotty/tools/tasty/TastyBuffer.scala does not exists, took 4.883 sec

@BarkingBad could you have a look at why this test is failing when using a nightly compiler as our reference compiler?

@BarkingBad
Copy link
Contributor

The RemoteLinksTest is supposed to test whether the source links are pointing to the correct repository and to the correct line. The source links of the new dotty classes are based on the referenceVersion property to build the link. It's not only the problem with the test, all the docs published after merging this PR will have source link url pointing to, for example: https://github.com/lampepfl/dotty/blob/3.0.2-RC1-bin-20210628-10145ff-NIGHTLY/library/src/scala/quoted/runtime/Expr.scala#L7, that will yield 404 (since the link is broken). We can either:

  • provide git tag for the reference version (the links will work)
  • remove referenceVersion property dependency from the calculated source-link and set it to be 3.0.0 for now (but we would have to update it after 3.0.1 release etc.
  • all other solutions with conditional logic/dictionaries

What solution do you like the most?

@anatoliykmetyuk
Copy link
Contributor

@anatoliykmetyuk Should #12672 be backported to release-3.0.1? As is, the compiler from that branch cannot be used as a reference compiler, so we can't release 3.0.1 without fixing that.

The functionality appears to already be present in 3.0.1 branch: https://github.com/lampepfl/dotty/blob/release-3.0.1/compiler/src/dotty/tools/dotc/config/Properties.scala#L91

@smarter
Copy link
Member Author

smarter commented Jun 30, 2021

@BarkingBad I'll let you choose what you think is best for maintaining this test, keeping in mind that we should really avoid having tests that can randomly start failing when something unrelated changes, so

remove referenceVersion property dependency from the calculated source-link and set it to be 3.0.0 for now (but we would have to update it after 3.0.1 release etc.

Seems fine to me.

@BarkingBad
Copy link
Contributor

I checked it once again and missed Krzysztof has made some enhancement for links to point them to hash commit rather than to git tag, but didn't apply it for tasty sources (which defaulted to 3.0.0). I made PR to this branch that should fix that dotty-staging#18

@smarter
Copy link
Member Author

smarter commented Jun 30, 2021

Can you open a separate pr for that? We might not end up merging this one.

@BarkingBad
Copy link
Contributor

Sure, here it is #12990

@dwijnand dwijnand modified the milestones: 3.0.1, 3.1.0 Jul 14, 2021
@SethTisue SethTisue added needs-minor-release This PR cannot be merged until the next minor release and removed needs-minor-release This PR cannot be merged until the next minor release labels Jul 26, 2021
@odersky
Copy link
Contributor

odersky commented Aug 23, 2021

Fixed by changes to @experimental.

@odersky odersky closed this Aug 23, 2021
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.

7 participants