witty-family-13337
01/12/2022, 1:13 PM./pants lint
on our whole repo (which has around 1500 Scala files):
Error: 6.11 [ERROR] Completed: Lint with scalafmt - scalafmt failed (exit code -6).
#
# A fatal error has been detected by the Java Runtime Environment:
#
# SIGSEGV (0xb) at pc=0x00007fb1f0e766f1, pid=5768, tid=5791
#
# JRE version: OpenJDK Runtime Environment (11.0+28) (build 11+28)
# Java VM: OpenJDK 64-Bit Server VM (11+28, mixed mode, tiered, compressed oops, g1 gc, linux-amd64)
# Problematic frame:
# V [libjvm.so+0xbf46f1] Node::add_req(Node*)+0xc1
#
# Core dump will be written. Default location: Core dumps may be processed with "/usr/share/apport/apport %p %s %c %d %P %E" (or dumping to /tmp/process-executionIMybnt/core.5768)
#
# An error report file with more information is saved as:
# /tmp/process-executionIMybnt/hs_err_pid5768.log
#
# Compiler replay data is saved as:
# /tmp/process-executionIMybnt/replay_pid5768.log
#
# If you would like to submit a bug report, please visit:
# <http://bugreport.java.com/bugreport/crash.jsp>
#
✓ Black succeeded.
✓ Docformatter succeeded.
✓ Flake8 succeeded.
✓ Google Java Format succeeded.
✓ Shellcheck succeeded.
✓ gofmt succeeded.
✓ hadolint succeeded.
✓ isort succeeded.
𐄂 scalafmt failed.
✓ shfmt succeeded.
just checking if you are aware of thishappy-kitchen-89482
01/12/2022, 2:17 PMwitty-family-13337
01/12/2022, 2:32 PMfast-nail-55400
01/12/2022, 4:08 PMwitty-family-13337
01/12/2022, 4:16 PM.scalafmt.conf
file for the whole repo, which is at the rootfast-nail-55400
01/12/2022, 4:18 PMwitty-family-13337
01/12/2022, 4:25 PMfast-nail-55400
01/12/2022, 4:28 PMdict
mapping config file to files to compute partitions. https://github.com/pantsbuild/pants/blob/3b1974c6879c82d512aabf1ab20dab76daab3523/src/python/pants/backend/scala/lint/scalafmt/rules.py#L237maybe it would make sense to partition by coarsened target still respecting the partition by file originally in placethat might result in tiny partitions since scalafmt just works on a file-by-file basis. for performance, we might prefer larger partitions (but not large enough to eat all of the memory … 🙂 )
I assuming that choosing an arbitrary number for “partition too large” may be the typical quest for not uncommon issue in Spark: how to choose a partition size 😅yes, exactly! and at that point, we’d have to take file size into account because of the potential for partition size skew 🙂
witty-crayon-22786
01/12/2022, 4:58 PMfast-nail-55400
01/12/2022, 5:08 PMwitty-crayon-22786
01/12/2022, 5:10 PMfast-nail-55400
01/12/2022, 5:13 PMwitty-crayon-22786
01/12/2022, 5:17 PMwitty-family-13337
01/12/2022, 5:23 PMjdk = "adopt:1.12"
to pants.toml
and run ./pants lint ::
. It runs properly, with no crasheshappy-kitchen-89482
01/12/2022, 11:34 PMwitty-crayon-22786
01/12/2022, 11:35 PMjdk
. all such information is ~guaranteed to be in cache keys.witty-family-13337
01/13/2022, 8:23 AMadopt
distribution has been moved to be Eclipse Temurintemurin:1.11
instead of adopt:1.11
?hundreds-father-404
01/13/2022, 8:08 PMmay be worth changing the default JVM in Pants to be temurin:1.11 instead of adopt:1.11?I don't know JVM well enough to say. Bump @witty-crayon-22786 @fast-nail-55400?
witty-crayon-22786
01/13/2022, 8:16 PMhundreds-father-404
01/13/2022, 8:17 PMwitty-crayon-22786
01/13/2022, 8:17 PMhundreds-father-404
01/13/2022, 8:23 PM>=3.6,<4
, which is a bad default now that 3.6 is EOLwitty-family-13337
01/14/2022, 9:32 AM