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

Merge upstream changes #118

Merged
merged 57 commits into from
Oct 11, 2022
Merged

Conversation

alexarchambault
Copy link
Collaborator

No description provided.

oyvindberg and others added 30 commits August 16, 2022 11:05
This commit changes the Bloop project definition to add a new field,
`sourceGenerators`, which can be used to define source generators.

Source generators are parts of the build that are run when Bloop gathers
the sources of a project (either when queried via BSP or when
compiling).

Source generators are configured with globs matching input files, an
output directory, and a program to run. When the inputs or known outputs
of a source generator change, the source generator is automatically
re-run. When there are no changes, the result of a source generator is
cached.

The command to execute to run a source generator will be built from the
configured `argv`, followed by the output directory and the input files.
Previously, Bloop would use types from `scala.sys.process` to run the
source generators. This commit migrates over to using Bloop's `Forker`.
Previously, Bloop would not work correctly when watching for changed,
and the inputs of source generators were changed.
Follow up to scalacenter#1759

I thought that it was fixed in scalacenter@2baf28a
but it seems that I got confused in locally published bloop versions.
Add support for source generators in Bloop
Previously, Bloop would not store the state of source generators after
their run, which would cause them to always be re-run, even when there
are no changes.
Co-authored-by: Tomasz Godzik <tgodzik@users.noreply.github.com>
…us-errors

show stack traces of `Error`s thrown in asynchronous code
Previously, the `buildTarget/sources` BSP request could fail in cases
where the build included source generators that depend on the output of
other source generators. This issue would happen because, in this case,
the ordering in which the source generators would run wasn't clearly
defined.

During a compilation task, this problem would not appear because the
source generators would always be run after their dependencies have run.

To fix this problem in the BSP services, Bloop will now run the source
generators in the topological order.
…al-sort

Run source generators in topological order
Previously, we would not download semanticdb even if it was backpublished. Now, we will try to download, but not print any warning if it's unsupported.
bugfix: Try to download semanticdb even if it might not be supported
- add `TestRun` and `TestRuns` structures to aggregate all produced `TestSuiteEvent.Results`.
- propagate all test results back up to service
- use test results to return `bsp.StatusCode.Error` on failed tests (Fixing scalacenter#960)
- ensure that the compilation before test finished with `StatusCode.Ok`
- not much for now, assert that we get correct exit codes
Bumps [scala-library](https://github.com/scala/scala) from 2.13.6 to 2.13.9.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](scala/scala@v2.13.6...v2.13.9)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-library
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [scala-library](https://github.com/scala/scala) from 2.13.6 to 2.13.9.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](scala/scala@v2.13.6...v2.13.9)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-library
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [scala-library](https://github.com/scala/scala) from 2.13.6 to 2.13.9.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](scala/scala@v2.13.6...v2.13.9)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-library
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
dependabot bot and others added 27 commits September 30, 2022 18:59
Bumps [scala-library](https://github.com/scala/scala) from 2.13.6 to 2.13.9.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](scala/scala@v2.13.6...v2.13.9)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-library
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
Bumps [scala-library](https://github.com/scala/scala) from 2.13.6 to 2.13.9.
- [Release notes](https://github.com/scala/scala/releases)
- [Commits](scala/scala@v2.13.6...v2.13.9)

---
updated-dependencies:
- dependency-name: org.scala-lang:scala-library
  dependency-type: direct:production
...

Signed-off-by: dependabot[bot] <support@github.com>
…/integrations/maven-bloop/src/test/resources/multi_scala/module2/org.scala-lang-scala-library-2.13.9

build(deps): bump scala-library from 2.13.6 to 2.13.9 in /integrations/maven-bloop/src/test/resources/multi_scala/module2
…/integrations/maven-bloop/src/test/resources/basic_scala/org.scala-lang-scala-library-2.13.9

build(deps): bump scala-library from 2.13.6 to 2.13.9 in /integrations/maven-bloop/src/test/resources/basic_scala
…/integrations/maven-bloop/src/test/resources/multi_dependency/module2/org.scala-lang-scala-library-2.13.9

build(deps): bump scala-library from 2.13.6 to 2.13.9 in /integrations/maven-bloop/src/test/resources/multi_dependency/module2
…/integrations/maven-bloop/src/test/resources/test_jars/org.scala-lang-scala-library-2.13.9

build(deps): bump scala-library from 2.13.6 to 2.13.9 in /integrations/maven-bloop/src/test/resources/test_jars
…/integrations/maven-bloop/src/test/resources/multi_dependency/module1/org.scala-lang-scala-library-2.13.9

build(deps): bump scala-library from 2.13.6 to 2.13.9 in /integrations/maven-bloop/src/test/resources/multi_dependency/module1
chore: set canDebug capabilities to true
bugfix: Revert to bsp 2.0.0, since later versions don't run on JDK 8
Reported by @kpodsiad

Prevosuly, even if a task was completing in defined duration the
fallaback effect were anyway exectured.
fix: bloop.task.Task - avoid materializing fallback task in timeoutTo
 Conflicts:
	docs/build-tools/gradle.md
 Conflicts:
	config/src/main/scala-2.10/bloop/config/ConfigCodecs.scala
	docs/assets/bloop-schema.json
	frontend/src/test/scala/bloop/util/TestUtil.scala
	integrations/gradle-bloop/src/main/scala/bloop/integrations/gradle/model/BloopConverter.scala
	integrations/gradle-bloop/src/test/scala/bloop/integrations/gradle/ConfigGenerationSuite.scala
	integrations/maven-bloop/src/main/scala/bloop/integrations/maven/MojoImplementation.scala
	integrations/sbt-bloop/src/main/scala/bloop/integrations/sbt/SbtBloop.scala
	project/BuildPlugin.scala
 Conflicts:
	integrations/maven-bloop/src/test/resources/basic_scala/pom.xml
	integrations/maven-bloop/src/test/resources/multi_dependency/module1/pom.xml
	integrations/maven-bloop/src/test/resources/multi_dependency/module2/pom.xml
	integrations/maven-bloop/src/test/resources/multi_scala/module2/pom.xml
	integrations/maven-bloop/src/test/resources/test_jars/pom.xml
@alexarchambault alexarchambault marked this pull request as ready for review October 11, 2022 16:14
@alexarchambault alexarchambault merged commit 162d07d into scala-cli:main Oct 11, 2022
@alexarchambault alexarchambault deleted the merge-upstream branch October 11, 2022 17:00
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.

8 participants