You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unfortunately sometimes an exception is thrown on code formatting (enabled on compile).
Problem
Exception occurs sometimes:
Caused by: java.lang.IllegalArgumentException: 109 is not a valid offset, allowed [0..0]
at scala.meta.inputs.Point$Offset.<init>(Point.scala:33)
at scala.meta.inputs.Point$Offset$.apply(Point.scala:30)
at metaconfig.typesafeconfig.TypesafeConfig2Class$.$anonfun$getPositionOpt$6(TypesafeConfig2Class.scala:73)
at scala.Option$WithFilter.map(Option.scala:146)
at metaconfig.typesafeconfig.TypesafeConfig2Class$.$anonfun$getPositionOpt$2(TypesafeConfig2Class.scala:66)
at scala.Option.flatMap(Option.scala:171)
at metaconfig.typesafeconfig.TypesafeConfig2Class$.$anonfun$getPositionOpt$1(TypesafeConfig2Class.scala:65)
at scala.Option.flatMap(Option.scala:171)
at metaconfig.typesafeconfig.TypesafeConfig2Class$.getPositionOpt(TypesafeConfig2Class.scala:64)
at metaconfig.typesafeconfig.TypesafeConfig2Class$.loop$1(TypesafeConfig2Class.scala:45)
Workaround
Usually another run of compile / format "fixes" the issue.
Notes
Using scalafmt in a play project. It seems that this exception occurs in sbt run task, maybe there is a problem with play's recompile mechanism?
The text was updated successfully, but these errors were encountered:
Thanks for reporting! The error seems related to reading the configuration file. Did you by any chance recently update the .scalafmt.conf file before this happened? If so, this is likely fixed in #1145 where we upgraded the configuration library to a version where subsequent reads from the same file are not cached.
This template is a guideline, not a strict requirement.
Steps
Unfortunately sometimes an exception is thrown on code formatting (enabled on compile).
Problem
Exception occurs sometimes:
Workaround
Usually another run of compile / format "fixes" the issue.
Notes
Using scalafmt in a play project. It seems that this exception occurs in sbt run task, maybe there is a problem with play's recompile mechanism?
The text was updated successfully, but these errors were encountered: