Skip to content
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

User JAR file path cannot be added to a custom classpath #65

Closed
pditommaso opened this issue Apr 1, 2015 · 6 comments
Closed

User JAR file path cannot be added to a custom classpath #65

pditommaso opened this issue Apr 1, 2015 · 6 comments
Labels

Comments

@pditommaso
Copy link

maven caplet should allow users to include their own jars to the classpath overriding the attribute method.

Currently the sanitize method does not allow that and raises the following exception:

CAPSULE EXCEPTION: Could not resolve item /Users/pditommaso/workspace/nextflow/gradle/wrapper/gradle-wrapper.jar
java.lang.RuntimeException: Could not resolve item /Users/pditommaso/workspace/nextflow/gradle/wrapper/gradle-wrapper.jar
    at Capsule.resolve(Capsule.java:2781)
    at Capsule.buildClassPath(Capsule.java:1858)
    at Capsule.buildJavaProcess(Capsule.java:1744)
    at Capsule.buildProcess0(Capsule.java:1273)
    at Capsule.buildProcess(Capsule.java:1264)
    at Capsule.buildProcess(Capsule.java:1264)
    at Capsule.buildProcess(Capsule.java:1264)
    at Capsule.prelaunch0(Capsule.java:1237)
    at Capsule.prelaunch(Capsule.java:1232)
    at CapsuleLoader.prelaunch(CapsuleLoader.java:45)
    at Capsule.prepareForLaunch(Capsule.java:1146)
    at Capsule.launch(Capsule.java:1091)
    at Capsule.main0(Capsule.java:332)
    at Capsule.main(Capsule.java:311)
Caused by: java.lang.IllegalArgumentException: Path /Users/pditommaso/workspace/nextflow/gradle/wrapper/gradle-wrapper.jar is not local to app cache /Users/pditommaso/.nextflow/capsule/apps/nextflow_0.13.0-SNAPSHOT
    at Capsule.sanitize(Capsule.java:3003)
    at Capsule.resolve(Capsule.java:2768)
    ... 13 more
Unable to initialize nextflow environment

https://groups.google.com/d/msg/capsule-user/1kkx8-Y58R0/E95C17QL4ZoJ

@pron pron added the bug label Apr 1, 2015
@danthegoodman
Copy link
Contributor

@pron I would like to point out that both paolo and myself have created custom capsules to add to the classpath after a capsule has been created via environment variables or system properties. We use ours to add logging dependencies after capsule creation, and I feel like this is a common enough use case to warrant including it in the core capsule functionality.

That said, would you rather this stay external as custom capsules? Or do you agree with me?

@pron
Copy link
Contributor

pron commented Apr 1, 2015

Well, I'm not 100% convinced, and when in doubt -- leave it out! (We can always add it later, but taking things out after a 1.0 release is not as simple).

In fact, as you can probably tell, the trend is to remove as much as possible from the core to caplets (I've removed all the Maven stuff). I even entertained the notion of moving all the JVM specific code (classpath etc.) to a caplet (so that core Capsule will just support attributes and buildProcess etc.), but thought that would be too much, as I don't expect people to use Caplet for non-JVM programs...

@danthegoodman
Copy link
Contributor

Sounds good to me 👍

@pditommaso
Copy link
Author

Is there a release or a snapshot including this patch?

@pditommaso
Copy link
Author

OK. I suppose it's included in the release 1.0-rc2-SNAPSHOT

@pron
Copy link
Contributor

pron commented Jul 15, 2015

Yep. Note that there will be no 1.0-rc1 release. We will release 1.0 in a couple of weeks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants