-
Notifications
You must be signed in to change notification settings - Fork 35
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
Scala script error #65
Comments
I get the same error - we both added the entries for scala in |
If you're trying to use latest master, you have to build mod-lang-scala jars locally and copy them over to you have to copy over the jar files. These are the instructions I use (adjust to your own env) when testing scripts with snapshot releases I build locally. |
Okay, so after doing this:
I don't have the jar files of So putting these Why is that? Is this a general Vert.x issue, that it needs the language modules in a really strange format and cannot do that itself on install? Do we have to change something in the gradle build? Will users have to do this themselves when they try to run Scala code? |
You shouldn't have to copy anything manually - perhaps you're not building mod-lang-scala properly with the jar files in it's lib directory? |
@purplefox we have the following structure in the module:
It looks like we need to have all the |
Most probably you have a classloader issue in the mod-lang-scala module. Did you implement the recommendation I made last time about removing the second classloader that was being specifically used for scripts? |
Looks like it doesn't have a second class loader anymore. @galderz knows more about the implementation now... |
This line looks suspicious to me: Does this mean it's setting the context class loader to null? |
Looks like this assembles the classpath for the interpreter: But it looks strange to me, can't the interpreter just load resources from the context classloader? It seems odd to have to construct it this way... |
As far as I know you cant, you have to explicitly set the interpreter's On Thu, Oct 24, 2013 at 7:19 PM, Tim Fox notifications@github.com wrote:
Ranie Jade Ramiso w: raniejaderamiso.com |
Guys, leave this with me and I'll sort it out :) |
… factory * Fixed resolution of class name as well. * Added clearer messages of what the Scala verticle factory tries to do and hide away scripting errors.
… factory * Fixed resolution of class name as well. * Added clearer messages of what the Scala verticle factory tries to do and hide away scripting errors.
My fault guys, I messed it up when I refactored the ScalaVerticleFactory to split the interpreter out. PR coming right up... |
* Fixed resolution of class name as well. * Added clearer messages of what the Scala verticle factory tries to do and hide away scripting errors.
This is very weird. While trying to verify fix for #69 this issue seems to have reappeared :|. This was working with the 2.0.x snapshot, so maybe when we switched to 2.1-M1 something changed in the way Vert.x module classloader. Looking into it... |
…f println * Correct source code root for interpreter boot classpath * Use a privileged action in order to figure out location root of the module * ScalaVerticleFactory should use a Logger instead of println
…f println * Correct source code root for interpreter boot classpath * Use a privileged action in order to figure out location root of the module * ScalaVerticleFactory should use a Logger instead of println
…f println * Correct source code root for interpreter boot classpath * Use a privileged action in order to figure out location root of the module * ScalaVerticleFactory should use a Logger instead of println
* Correct source code root for interpreter boot classpath * Use a privileged action in order to figure out location root of the module * ScalaVerticleFactory should use a Logger instead of println
Fixed properly now. Apologies for the inconvenience. |
I still get this error when using 2.1M2 ? λ omnivore scala → λ git master → vertx run http/Server.scala Failed in deploying verticle |
You are using the latest available release, 0.2.0, which is known to have that issue. In the mean time, please do |
Can't start scala script with newest master. I tried running this code with "vertx run Server.scala":
and got this error:
The text was updated successfully, but these errors were encountered: