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

Enable generation of TASTy files readable for older compilers #14156

Merged
merged 22 commits into from Jan 19, 2022
Merged
Show file tree
Hide file tree
Changes from 21 commits
Commits
Show all changes
22 commits
Select commit Hold shift + click to select a range
a398130
Run test groups with different compiler versions
Kordyjan Oct 28, 2021
14719cf
Add -scala-release flag
Kordyjan Nov 8, 2021
99e0cc2
Output specified tasty version
Kordyjan Nov 8, 2021
1c17ea8
Handle classpath substitution in classpath
Kordyjan Nov 9, 2021
1455c4b
Fix pickler tests
Kordyjan Nov 10, 2021
22e8f8f
Change `-scala-release` flag into proper VersionSetting
Kordyjan Nov 15, 2021
ab3efcf
Add `since` annotation
Kordyjan Nov 16, 2021
44ffb68
Add since annotations to all symbols added in 3.1
Kordyjan Nov 16, 2021
f75c5ee
Restrict scope of `since` annotation
Kordyjan Nov 16, 2021
f1bae32
Check for types with `since` annotation
Kordyjan Nov 17, 2021
465ef4c
wip
Kordyjan Nov 22, 2021
42160dc
Finalize work on @since and -scala-release:
prolativ Dec 20, 2021
46b59c9
Reworks for forward compat:
prolativ Dec 28, 2021
72cb484
Use a more portable way to download an old compiler for tests
prolativ Dec 29, 2021
52f0177
scala-release: Adjust MiMa filters; Revert changes to tasty module
prolativ Dec 29, 2021
e39b618
-Yscala-release support: extend community build with basic forward-co…
prolativ Jan 12, 2022
e1f00c8
-Yscala-release support: test cats-effect compiled with scala 3.0.2 w…
prolativ Jan 13, 2022
f2aede6
-Yscala-release support: Improve caching artifacts downloaded for tests
prolativ Jan 14, 2022
3f88de4
-Yscala-release support: temporarily enable forward compat community …
prolativ Jan 14, 2022
a86db05
-Yscala-release support: checking if classes come from stdlib based o…
prolativ Jan 17, 2022
0c8ac84
-Yscala-release support: checking if classes come from stdlib based o…
prolativ Jan 18, 2022
85cf9be
-Yscala-release support: fix documentation; run extended CI only for …
prolativ Jan 19, 2022
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
45 changes: 44 additions & 1 deletion .github/workflows/ci.yaml
Expand Up @@ -317,6 +317,49 @@ jobs:
git submodule update --init --recursive --jobs 7
./project/scripts/sbt "community-build/testOnly dotty.communitybuild.CommunityBuildTestC"

community_build_forward_compat:
runs-on: [self-hosted, Linux]
container:
image: lampepfl/dotty:2021-03-22
options: --cpu-shares 4096
volumes:
- ${{ github.workspace }}/../../cache/sbt:/root/.sbt
- ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
- ${{ github.workspace }}/../../cache/general:/root/.cache
if: "github.event_name == 'schedule' && github.repository == 'lampepfl/dotty'
|| github.event_name == 'push'
|| (
github.event_name == 'pull_request'
&& !contains(github.event.pull_request.body, '[skip ci]')
&& !contains(github.event.pull_request.body, '[skip community_build]')
)
|| (
github.event_name == 'workflow_dispatch'
&& github.repository == 'lampepfl/dotty'
)"

steps:
- name: Reset existing repo
run: git -c "http.https://github.com/.extraheader=" fetch --recurse-submodules=no "https://github.com/lampepfl/dotty" && git reset --hard FETCH_HEAD || true

- name: Checkout cleanup script
uses: actions/checkout@v2

- name: Cleanup
run: .github/workflows/cleanup.sh

- name: Git Checkout
uses: actions/checkout@v2

- name: Add SBT proxy repositories
run: cp -vf .github/workflows/repositories /root/.sbt/ ; true

- name: Test
run: |
git submodule sync
git submodule update --init --recursive --jobs 7
./project/scripts/sbt "community-build/testOnly dotty.communitybuild.CommunityBuildTestForwardCompat"

test_sbt:
runs-on: [self-hosted, Linux]
container:
Expand Down Expand Up @@ -415,7 +458,7 @@ jobs:
- ${{ github.workspace }}/../../cache/sbt:/root/.sbt
- ${{ github.workspace }}/../../cache/ivy:/root/.ivy2/cache
- ${{ github.workspace }}/../../cache/general:/root/.cache
needs: [test_non_bootstrapped, test, community_build_a, community_build_b, community_build_c, test_sbt, test_java8]
needs: [test_non_bootstrapped, test, community_build_a, community_build_b, community_build_c, community_build_forward_compat, test_sbt, test_java8]
if: "(github.event_name == 'schedule' || github.event_name == 'workflow_dispatch') && github.repository == 'lampepfl/dotty'"
env:
NIGHTLYBUILD: yes
Expand Down
31 changes: 31 additions & 0 deletions .gitmodules
Expand Up @@ -219,3 +219,34 @@
[submodule "community-build/community-projects/spire"]
path = community-build/community-projects/spire
url = https://github.com/dotty-staging/spire.git
[submodule "community-build/community-projects/munit-forward-compat"]
path = community-build/community-projects/munit-forward-compat
url = https://github.com/dotty-staging/munit.git
[submodule "community-build/community-projects/discipline-forward-compat"]
path = community-build/community-projects/discipline-forward-compat
url = https://github.com/dotty-staging/discipline.git
[submodule "community-build/community-projects/discipline-munit-forward-compat"]
path = community-build/community-projects/discipline-munit-forward-compat
url = https://github.com/dotty-staging/discipline-munit.git
[submodule "community-build/community-projects/discipline-specs2-forward-compat"]
path = community-build/community-projects/discipline-specs2-forward-compat
url = https://github.com/dotty-staging/discipline-specs2.git
[submodule "community-build/community-projects/simulacrum-scalafix-forward-compat"]
path = community-build/community-projects/simulacrum-scalafix-forward-compat
url = https://github.com/dotty-staging/simulacrum-scalafix.git
[submodule "community-build/community-projects/cats-forward-compat"]
path = community-build/community-projects/cats-forward-compat
url = https://github.com/dotty-staging/cats.git
[submodule "community-build/community-projects/cats-mtl-forward-compat"]
path = community-build/community-projects/cats-mtl-forward-compat
url = https://github.com/dotty-staging/cats-mtl.git
[submodule "community-build/community-projects/coop-forward-compat"]
path = community-build/community-projects/coop-forward-compat
url = https://github.com/dotty-staging/coop.git
[submodule "community-build/community-projects/cats-effect-3-forward-compat"]
path = community-build/community-projects/cats-effect-3-forward-compat
url = https://github.com/dotty-staging/cats-effect.git
branch = series/3.x
[submodule "community-build/community-projects/scalacheck-forward-compat"]
path = community-build/community-projects/scalacheck-forward-compat
url = https://github.com/dotty-staging/scalacheck
2 changes: 1 addition & 1 deletion community-build/README.md
Expand Up @@ -17,6 +17,6 @@ To add your project to the community build you can follow these steps:

2. Open a PR against this repo that:
- Adds your project as a new git submodule
- `git submodule add https://github.com/lampepfl/XYZ.git community-build/community-projects/XYZ`
- `git submodule add https://github.com/dotty-staging/XYZ.git community-build/community-projects/XYZ`
- Add the project to [projects.scala](https://github.com/lampepfl/dotty/blob/master/community-build/src/scala/dotty/communitybuild/projects.scala)
- Adds a test in [CommunityBuildTest.scala](https://github.com/lampepfl/dotty/blob/master/community-build/test/scala/dotty/communitybuild/CommunityBuildTest.scala)
1 change: 1 addition & 0 deletions community-build/community-projects/cats-forward-compat
Submodule cats-forward-compat added at 878472
1 change: 1 addition & 0 deletions community-build/community-projects/cats-mtl-forward-compat
1 change: 1 addition & 0 deletions community-build/community-projects/coop-forward-compat
Submodule coop-forward-compat added at 4babee
1 change: 1 addition & 0 deletions community-build/community-projects/munit-forward-compat
Submodule munit-forward-compat added at 662953
Expand Up @@ -17,10 +17,10 @@ object CommunityBuildRunner:
* for more infrastructural details.
*/
extension (self: CommunityProject) def run()(using suite: CommunityBuildRunner): Unit =
if self.requiresExperimental && !compilerSupportExperimental then
if self.requiresExperimental && !self.compilerSupportExperimental then
log(s"Skipping ${self.project} - it needs experimental features unsupported in this build.")
return
self.dependencies.foreach(_.publish())
self.dependencies().foreach(_.publish())
self.testOnlyDependencies().foreach(_.publish())
suite.runProject(self)

Expand All @@ -45,6 +45,7 @@ trait CommunityBuildRunner:
val project = projectDef.project
val command = projectDef.binaryName
val arguments = projectDef.buildCommands
val compilerVersion = projectDef.compilerVersion

@annotation.tailrec
def execTimes(task: () => Int, timesToRerun: Int): Boolean =
Expand Down
2 changes: 1 addition & 1 deletion community-build/src/scala/dotty/communitybuild/Main.scala
Expand Up @@ -57,7 +57,7 @@ object Main:
val (toRun, ignored) =
allProjects.partition( p =>
p.docCommand != null
&& (!p.requiresExperimental || compilerSupportExperimental)
&& (!p.requiresExperimental || p.compilerSupportExperimental)
)

val paths = toRun.map { project =>
Expand Down