These are chat archives for ensime/ensime-atom

7th
Mar 2016
Magnus Andersson
@magnusart
Mar 07 2016 12:43
Hi, is it possible to mute certain warnings in the presentation compiler? I get Procedure syntax is deprecated in over 200 locations at work.
Magnus Andersson
@magnusart
Mar 07 2016 12:59
Nevermind I fixed the warnings. But it would be nice to have control over that.
Magnus Andersson
@magnusart
Mar 07 2016 13:22
The presentation compiler seems to be looking at generated content, like twirl templates and play routes. I get tons of warnings for unused imports. Is an issue on the client or the server side?
Magnus Andersson
@magnusart
Mar 07 2016 13:36
I get 717 issues (both errors and warnings) for code that compiles without any issues in sbt. Many errors seems to be false positives. Have anyone else had the same experience?
Rory Graves
@rorygraves
Mar 07 2016 13:47
@magnusart you may get some errors around macros, the presentation compiler does not try hard enough with them. Unlike the full compilation. Fommil has some work in progress around imaginary friend, a compiler plugin to allow macro writers to help the PC. The twirl and routes issue is down to the src paths in your .ensime. Try removing the offending path.
Unused imports is a compiler flag, look at the flags being passed in .ensime and adjust to taste.
Magnus Andersson
@magnusart
Mar 07 2016 13:54
@rorygraves thanks, I found the .ensime source paths for twirl and routes. That made a lot of things go away.
Rory Graves
@rorygraves
Mar 07 2016 13:55
Cool.
Magnus Andersson
@magnusart
Mar 07 2016 14:04
Still get compilation errors that do not show up in sbt.
Rory Graves
@rorygraves
Mar 07 2016 14:07
Can you give some examples?
Magnus Andersson
@magnusart
Mar 07 2016 14:11
Well let’s pick out one.
too many arguments for method :+: (elem: (String, …)...
defaultButtons :+= (s"CatGroup[$groupIndex]", FormFrontPageButton(
                title      = formDef.categoryGroups(groupIndex).frontPageButtonTitle,
                buttonType = FormFrontPageButtonType.categoryGroup,
                index      = Some(groupIndex)
            ))
The type of defaultButtons is Seq[Tuple2[String, FormFrontPageButton]]. I haven’t written that code and there are a lot of similar things found that compiles in sbt.
I now see messages saying the presentation compiler crashes while type checking certain files. Perhaps that has to do with it.
Magnus Andersson
@magnusart
Mar 07 2016 14:23
The presentation compiler seems to be constantly restarting as well. It starts listing issues and then restarts over and over again. Even when setting the typecheck trigger to save only.
Rory Graves
@rorygraves
Mar 07 2016 14:28
Could be. Can you capture the exception around the PC crash?
Magnus Andersson
@magnusart
Mar 07 2016 14:38
scala.reflect.internal.FatalError: no progress in completing object CompanyUserGroupsService: <?>
No stacktrace though
Actually I have the stacktrace in the server logs if it is of interest.
Debugging atom it seems the server is sending ”NewScalaNotesEvent” notifications over and over.
It stops if I do not touch anything but if I navigate around it starts again (but not editing or typing)
Magnus Andersson
@magnusart
Mar 07 2016 14:43
One observation is that this project have many modules. I don’t see the same thing in a simpler project like akka-persistence-cassandra. Scratch that, I see the same behavior.
Rory Graves
@rorygraves
Mar 07 2016 14:50
Weird on the notes. That's triggered by s typecheck file request. Can you see those when navigating open files with no editing?
The stacktace is useful. Can you throw it in a gist?
Magnus Andersson
@magnusart
Mar 07 2016 14:52
Yes I can see it in an empty editor, but I realized I issued the "typecheck all” command (not sure what that translates to in ensime-server). So maybe it is the client not playing nice.
Lost the stacktrace for now (logs overwritten on restart) but I can probably reproduce it.
trepidacious
@trepidacious
Mar 07 2016 23:01
Anyone seen this? 22:52:34.812 ERROR None Server - Shutdown requested due to internal error: java.lang.NumberFormatException: For input string: "61872\n" <- note \n is an actual newline... Running from atom.
Rory Graves
@rorygraves
Mar 07 2016 23:37
Sounds like it's failed to parse the port file. Looks like the read function needs a .trim