Dear Scala Contributors,
Darja here, new communication intern at Scala Center!
I will do my best to keep you up to date with all the developments from our side (SIP, SPP meetings, project developments and more!)
Starting today with September/October project report form Scala Center Team and updating you in months to come.
Let’s begin:
At a glance
Ólafur Páll Geirsson @olafurpg
- Scalafix
- Macros
Jorge Vicente Cantero @jvican
- Compiler Profiling (SCP-010)
- Zinc Profiling (SCP-015)
sbt-release-early
Guillaume Massé @MasseGuillaume
- Scastie
- Scala.js-Bundler
- Scaladex
Martin Duhem @Duhemm
- Scala Native
- Dotty
- Generating java generic signatures
- Specializing Functions
Julien Richard-Foy @julienrf
- Collections (SCP-007)
- Scalajs-bundler (SCP-005)
- MOOCs
Other activities
Presentations and workshops
Scalafix
Ólafur Páll Geirsson @olafurpg
-
scalacenter/scalafix#386 Review a rewrite of scalafix docs/website,
contribution from @gabro. -
scalacenter/scalafix#389 remove usage of scalamacros/paradise, unblocking
generation of API scaladocs. - scalacenter/scalafix#388 emit linter warnings from scalafix-cli.
- scalacenter/scalafix#382 fix bug in addGlobalImport patch.
Macros
Ólafur Páll Geirsson @olafurpg
- Posted “Roadmap towards non-experimental macros”
- Initiated Scala contributors discussions on
- scalacenter/dotty#1: Add infrastructure to expand macros in Dotty.
- scalacenter/macros#16: Add Dotty engine to new macro system.
Now that we have integration tests expanding macros for both dotc and scalac,
the next steps are to iterate on the design of the macro system to improve
the API for both macro authors and compiler engineers implementing macro engines.
Compiler Profiling (SCP-010)
Jorge Vicente Cantero @jvican
Got the open PRs to scala/scala to the finish line and merged in 2.12.4.
2.12.4 is expected to be released next week.
- Collect all statistics and optimize checks.
- Initialize statistics per global.
- Add extra timers and counters.
The feedback was great and concise, which also helped me to improve the current
implementation and reduce the performance impact of some changes. After
fundamental changes to the statistics engine, the Scala compiler performance
without enabled statistics has stayed the same.
The scalac-profiling repo has
been updated to the latest master in 2.12.4,
incorporating all the changes required in the review processes of the now merged
PRs.
The sbt plugin has been
reworked because the
previous implementation was using an incorrect approach to the profiling
problem. There is now a README for the sbt-plugin that explains:
- How to use the plugin (run
profilingWarmupCompiler
in any project). - How to get reliable data out of a profiled compiler (avoiding common pitfalls).
I am now working on getting a release out.
After the release is out, the plan is to write a technical guide that will
explain Scala developers how they can read the statistics and improve their
compile times.
Zinc Profiling SCP-015
Jorge Vicente Cantero @jvican
- Started to prototype a successful plan for SCP-015. This involves planning the
best roadmap to fulfill all the proposal’s requirements. - Held discussion with the sbt team (Eugene Yokota and Dale Wijnand). In the
chat, I explained technical details of SCP-015 and the incremental compiler.
I also proposed a modular way to upstream changes gradually. All the work will
initially happen inscalacenter/zinc
.
Zinc
Jorge Vicente Cantero @jvican
-
Fixed #389: Ignore null in generic lambdas parameters.
This bug was the only blocker for Twitter to adopt Zinc 1.0. - Reviewed fix to only-2.11 bug with trait encoding.
sbt-release-early
Jorge Vicente Cantero @jvican
Several improvements to sbt-release-early
. I worked on the plugin to polish
the rough edges that I found while hacking up the release configuration in
scalac-profiling.
- Reviewed and fixed Alexey Alekhin’s (a new external maintainer of the project)
sbt 1.0 support insbt-release-early
. See this PR. - Rescope settings to
Global
in #12. - Allow users to disable instant releases in #15.
- Make Sonatype the default publisher in #14.
Scastie
Guillaume Massé @MasseGuillaume
Completed the embedded mode for Scastie.
This embedding shows how we can use Scastie to document Dotty:
We can bootstrap the embedding with various mechanisms. Read the documentation for more details.
There is a pull request to add Scastie to the front page of https://scala-lang.org.
63 Commits for 2017-09-12 to 2017-10-10
Scala.js-Bundler
Guillaume Massé @MasseGuillaume
I made some changes on the Scala.js-Bundler to fit Scastie’s needs:
Scaladex
Guillaume Massé @MasseGuillaume
Unified the support for sbt in Scaladex. It allows for the following queries:
Added support for full Scala version. It allows for the following queries:
- Search for libraries released for 2.13.0-M1 but not released for 2.13.0-M2
- Search for libraries released for 2.13.0-M1 and 2.13.0-M2
Missing artifact versions:
Sonatype is pushing updates directly to Scaladex when they receive new releases. However, before
this collaboration, we are still missing some artifacts. I wrote a script to retrieve those artifacts.
Misc fixes / Improvements:
- Excluded internal dependencies / group by projects in Most-Depends-On
- Bug fix for sbt resolver
- Bug fix for sbt resolver (2)
Scala Native
Martin Duhem @Duhemm
I set up a new continuous integration server for Scala Native
to avoid all the problems that we were facing with Travis (timeouts, spurious failures, etc.)
The new CI, based on Jenkins CI, is much faster and giving more reliable
results.
The new CI has already uncovered several bugs in the new garbage collector and
the I/O module of Scala Native.
Dotty
Martin Duhem @Duhemm
Generating java generic signatures
I added support for
generating Java Generic Signatures in the compiler. This task has ben done and
is currently being reviewed. The goal is to generate signatures for classes,
methods, etc. that can be understood by javac
, following the Java Virtual
Machine Specification §4.3.4
The initial review of this work
allowed us to uncover a bug in scalac
, where the bounds of a type parameter
didn’t fully reflect the actual bounds. As a result, it was possible to get runtime
crashes when using generic definitions written in Scala, from Java. The bug
has been reported, and will not be present
in dotc
.
This work, which improves interoperability between code compiled with dotc
and javac
, is expected to be part of 0.5 release of Dotty.
Specializing Functions
Prior work by Felix Mulder aimed at
adding an optimisation that would improve the performance of code compiled by dotc
by specializing calls to the apply
method of Function{0,1,2}
. Because of a bug in
dotc
, this work was put on hold. Now that the bug has been fixed, I picked up his
previous work and continued it.
The PR with the new changes has been
submitted and is currently being reviewed. I expect that this will land in the 0.5
release of dotc
.
Collections [SCP-007)
Julien Richard-Foy @julienrf
- Wrote documentation about the architecture and conventions of the collections strawman.
- Made Views effectively
Iterable
#237.
Prior to this PR it was possible to mistakenly build aView
that was only iterable once.
Now this is possible only by using the explicitfromIteratorProvider
method. - Polled the community about new operations or collections to add. Got a hundred of responses.
- Introduce two kinds of implicit collection factories: one (
BuildFrom
) whose resulting
collection type depends on the runtime type of a source collection and one (Factory
)
whose resulting collection type depends on a given static type. #249 - Added
LinkedHashMap
andLinkedHashSet
#248 - Added
MultiSet
collection andupdateWith
operation #263 - Added
MultiMap
collection #262 - Fixed equality of Views #261
- Added
NonEmpty
collection type, ensuring that an underlying collection has at least
one element #260 - Added
join
-like operations #259 - Optimized
List#updated
#258
Scalajs-bundler (SCP-005)
Julien Richard-Foy @julienrf
Reviewed and merged pull requests:
- cross-building of sbt plugins for sbt 1.0 #179
- bump default Webpack version to 3.x #175
- scope bundling mode per Scala.js stage #177
- fix webpack-dev-server installation #176
Worked on making it possible to publish a release by pushing a Git tag #184
MOOCs
Julien Richard-Foy @julienrf
Worked on a new, self-hosted, clusterized, grading infrastructure intended to be
interoperable with more learning management systems.
Other activities
Presentations and workshops
Open Source Sprees
Open Source Spree at Scala World (September 18-21)
Ólafur Páll Geirsson @olafurpg
Organized Open Source Spree with 35 attendees,
https://twitter.com/olafurpg/status/910532588925849603
Preparation for Open Source Spree at Lambda World (October)
Jorge Vicente Cantero @jvican
We’re having a spree in Lambda World at the end of October. To continue our
successes in previous events, I have reported bugs and feature improvements in
sbt/sbt
, sbt/sbt-bintray
, scalacenter/sbt-release-early
, documenting them
appropriately so that beginners can tackle them.
Presentations/Workshops at Scala World
Heather Miller @heathermiller
Presentation “Some Trends in Open Source/The State of Scala Center” (presentation slides)
Ólafur Páll Geirsson @olafurpg
- Attended two day conference, where for example @gabro hosted a 90 minute
workshop on Scalafix, https://speakerdeck.com/gabro/move-fast-and-fix-things - Hosted Typelevel workshop on Scalameta Semantic API, where
the group of 10 participants solved a “Jump to definition”
bug scalameta/metadoc#75 - Presented “Next-generation Scala Developer tools”
over lunch at Cake Solutions.