[jira] [Commented] (IVY-1553) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib or forking another java process with classpath explicitly configured to cont

2016-12-11 Thread JIRA

[ 
https://issues.apache.org/jira/browse/IVY-1553?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15741224#comment-15741224
 ] 

Reşat SABIQ commented on IVY-1553:
--

There is another work-around to this issue, & updated the issue title to 
reflect this. In short, as of now, PGP signing during publication throws CNFE 
in normal workflow. Workarounds are:
1. Place bouncy castle dependency in an ant-wide lib folder, like .ant/lib.
2. Retrieve dependencies, & then fork a new java process with classpath 
explicitly configured to contain bouncy castle modules running an "internal"ish 
ant task in the new process.

P.S. The workarounds are enough to get the job done, but have drawbacks like:
1.1.1: requiring extra steps before building
OR
1.1.2: automatically putting the jars there, and asking the build to be re-run.
1.1.2.1: extra time & code required to automatically place the modules, and ask 
the build to be re-run.
1.2: potentially contaminating or corrupting ant-wide lib folder(s).
2.1: extra steps are required to pass on environment variables to make sure the 
forked process has everything needed to work right.
2.2: the internal task could still be accidentally used instead of the wrapping 
task, causing confusion.
2.3: extra time & code required to write the wrapping task forking a new 
process.

> PGP signing during publication shouldn't require bouncy castle dependencies 
> to be in .ant/lib or forking another java process with classpath explicitly 
> configured to contain bouncy castle modules
> ---
>
> Key: IVY-1553
> URL: https://issues.apache.org/jira/browse/IVY-1553
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0
>Reporter: Reşat SABIQ
>  Labels: pgp
>
> With
>   
>password="${pgp.password}"/> 
>   
> in ivysettings.xml,
> ivy kept throwing CNFE until i put these dependencies in .ant/lib:
>rev="1.49" conf="default"/>
>rev="1.49" conf="default"/>
> I ended up putting the following comment in ivy.xml:
>   
> P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (IVY-1553) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib or forking another java process with classpath explicitly configured to contai

2016-12-11 Thread JIRA

 [ 
https://issues.apache.org/jira/browse/IVY-1553?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Reşat SABIQ updated IVY-1553:
-
Summary: PGP signing during publication shouldn't require bouncy castle 
dependencies to be in .ant/lib or forking another java process with classpath 
explicitly configured to contain bouncy castle modules  (was: PGP signing 
during publication shouldn't require bouncy castle dependencies to be in 
.ant/lib)

> PGP signing during publication shouldn't require bouncy castle dependencies 
> to be in .ant/lib or forking another java process with classpath explicitly 
> configured to contain bouncy castle modules
> ---
>
> Key: IVY-1553
> URL: https://issues.apache.org/jira/browse/IVY-1553
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0
>Reporter: Reşat SABIQ
>  Labels: pgp
>
> With
>   
>password="${pgp.password}"/> 
>   
> in ivysettings.xml,
> ivy kept throwing CNFE until i put these dependencies in .ant/lib:
>rev="1.49" conf="default"/>
>rev="1.49" conf="default"/>
> I ended up putting the following comment in ivy.xml:
>   
> P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (IVY-1553) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib

2016-12-11 Thread JIRA

[ 
https://issues.apache.org/jira/browse/IVY-1553?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739596#comment-15739596
 ] 

Reşat SABIQ commented on IVY-1553:
--

Stack trace (got the same using cmd & cygwin bash shell):
build.xml:151: java.lang.NoClassDefFoundError: 
org/bouncycastle/openpgp/PGPException
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
at java.lang.Class.getConstructor0(Class.java:3075)
at java.lang.Class.newInstance(Class.java:412)
at org.apache.ivy.util.Configurator.addChild(Configurator.java:585)
at 
org.apache.ivy.util.Configurator.startCreateChild(Configurator.java:502)
at 
org.apache.ivy.core.settings.XmlSettingsParser.inConfiguratorStarted(XmlSettingsParser.java:579)
at 
org.apache.ivy.core.settings.XmlSettingsParser.startElement(XmlSettingsParser.java:201)
at 
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.startElement(AbstractSAXParser.java:509)
at 
com.sun.org.apache.xerces.internal.parsers.AbstractXMLDocumentParser.emptyElement(AbstractXMLDocumentParser.java:182)
at 
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanStartElement(XMLDocumentFragmentScannerImpl.java:1343)
at 
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(XMLDocumentFragmentScannerImpl.java:2786)
at 
com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(XMLDocumentScannerImpl.java:606)
at 
com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(XMLDocumentFragmentScannerImpl.java:510)
at 
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:848)
at 
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(XML11Configuration.java:777)
at 
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.java:141)
at 
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(AbstractSAXParser.java:1213)
at 
com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(SAXParserImpl.java:649)
at 
com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(SAXParserImpl.java:333)
at javax.xml.parsers.SAXParser.parse(SAXParser.java:274)
at 
org.apache.ivy.core.settings.XmlSettingsParser.doParse(XmlSettingsParser.java:160)
at 
org.apache.ivy.core.settings.XmlSettingsParser.parse(XmlSettingsParser.java:150)
at org.apache.ivy.core.settings.IvySettings.load(IvySettings.java:393)
at org.apache.ivy.Ivy.configure(Ivy.java:417)
at 
org.apache.ivy.ant.IvyAntSettings.createIvyEngine(IvyAntSettings.java:289)
at 
org.apache.ivy.ant.IvyAntSettings.getConfiguredIvyInstance(IvyAntSettings.java:247)
at 
org.apache.ivy.ant.IvyAntSettings.getConfiguredIvyInstance(IvyAntSettings.java:256)
at org.apache.ivy.ant.IvyTask.getIvyInstance(IvyTask.java:89)
at org.apache.ivy.ant.IvyTask.prepareTask(IvyTask.java:250)
at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:270)
at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
at 
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:497)
at 
org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
at org.apache.tools.ant.Task.perform(Task.java:348)
at org.apache.tools.ant.Target.execute(Target.java:435)
at org.apache.tools.ant.Target.performTasks(Target.java:456)
at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
at 
org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
at org.apache.tools.ant.Main.runBuild(Main.java:851)
at org.apache.tools.ant.Main.startAnt(Main.java:235)
at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
Caused by: java.lang.ClassNotFoundException: 
org.bouncycastle.openpgp.PGPException
at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
... 47 more


> PGP signing during publication shouldn't require bouncy castle dependencies 
> to be in .ant/lib
> -
>
> Key: IVY-1553
> 

[jira] [Closed] (IVY-1552) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib

2016-12-11 Thread JIRA

 [ 
https://issues.apache.org/jira/browse/IVY-1552?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Reşat SABIQ closed IVY-1552.

Resolution: Duplicate

JIRA submitted this one, but made me think it hadn't (when i clicked on a menu 
after clicking submit).

> PGP signing during publication shouldn't require bouncy castle dependencies 
> to be in .ant/lib
> -
>
> Key: IVY-1552
> URL: https://issues.apache.org/jira/browse/IVY-1552
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0
>Reporter: Reşat SABIQ
>  Labels: pgp
>
> With
>   
>password="${pgp.password}"/> 
>   
> in ivysettings.xml,
> ivy kept throwing CNFE until i put these dependencies in .ant/lib:
>rev="1.49" conf="default"/>
>rev="1.49" conf="default"/>
> I ended up putting the following comment in ivy.xml:
>   
> P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (IVY-1553) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib

2016-12-11 Thread JIRA

[ 
https://issues.apache.org/jira/browse/IVY-1553?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739552#comment-15739552
 ] 

Reşat SABIQ commented on IVY-1553:
--

The error thrown for me was the same as in this previously reported issue:
https://issues.liferay.com/browse/IDE-1172

I'm using 2.4.0, w/ ant 1.9.4.

> PGP signing during publication shouldn't require bouncy castle dependencies 
> to be in .ant/lib
> -
>
> Key: IVY-1553
> URL: https://issues.apache.org/jira/browse/IVY-1553
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0
>Reporter: Reşat SABIQ
>  Labels: pgp
>
> With
>   
>password="${pgp.password}"/> 
>   
> in ivysettings.xml,
> ivy kept throwing CNFE until i put these dependencies in .ant/lib:
>rev="1.49" conf="default"/>
>rev="1.49" conf="default"/>
> I ended up putting the following comment in ivy.xml:
>   
> P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Created] (IVY-1553) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib

2016-12-11 Thread JIRA
Reşat SABIQ created IVY-1553:


 Summary: PGP signing during publication shouldn't require bouncy 
castle dependencies to be in .ant/lib
 Key: IVY-1553
 URL: https://issues.apache.org/jira/browse/IVY-1553
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: 2.4.0
Reporter: Reşat SABIQ


With

 

in ivysettings.xml,
ivy kept throwing CNFE until i put these dependencies in .ant/lib:



I ended up putting the following comment in ivy.xml:


P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Created] (IVY-1552) PGP signing during publication shouldn't require bouncy castle dependencies to be in .ant/lib

2016-12-11 Thread JIRA
Reşat SABIQ created IVY-1552:


 Summary: PGP signing during publication shouldn't require bouncy 
castle dependencies to be in .ant/lib
 Key: IVY-1552
 URL: https://issues.apache.org/jira/browse/IVY-1552
 Project: Ivy
  Issue Type: Bug
  Components: Core
Affects Versions: 2.4.0
Reporter: Reşat SABIQ


With

 

in ivysettings.xml,
ivy kept throwing CNFE until i put these dependencies in .ant/lib:



I ended up putting the following comment in ivy.xml:


P.S. I believe this issue is ongoing since 2012/13.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (IVY-1482) NPE in XmlReportOutputter

2016-12-11 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1482?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739376#comment-15739376
 ] 

ASF GitHub Bot commented on IVY-1482:
-

GitHub user jaikiran opened a pull request:

https://github.com/apache/ant-ivy/pull/12

IVY-1482 Fix potential NPE in XmlReportOutputter

The commit here adds a null check to prevent potential NPE reported in JIRA 
https://issues.apache.org/jira/browse/IVY-1482


You can merge this pull request into a Git repository by running:

$ git pull https://github.com/jaikiran/ant-ivy ivy-1482

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/ant-ivy/pull/12.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #12


commit 0dc25d1d378861f2528b3de655afbced7c2f5a06
Author: Jaikiran Pai 
Date:   2016-12-11T08:48:37Z

IVY-1482 Fix potential NPE in XmlReportOutputter




> NPE in XmlReportOutputter
> -
>
> Key: IVY-1482
> URL: https://issues.apache.org/jira/browse/IVY-1482
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0-RC1
>Reporter: M Kim
>
> {code}
> public void output(ConfigurationResolveReport report, String resolveId, 
> String[] confs, ResolutionCacheManager cacheMgr) throws IOException {
>  File reportFile = 
> cacheMgr.getConfigurationResolveReportInCache(resolveId,
> report.getConfiguration());
>  File reportParentDir = reportFile.getParentFile();
>  reportParentDir.mkdirs(); // NPE
>  OutputStream stream = new FileOutputStream(reportFile);
>  writer.output(report, confs, stream);
>  stream.close();
>  //...
> }
> {code}
> In XmlReportOutputter.output method, NPE occurs when 
> reportFile.getParentFile() returns null. I think a proper error handling is 
> needed for reportFile and reportParentDir before OutputStream is created.
> 
> {code}
> public void test1() {
>   Ivy14 ivy = new org.apache.ivy.Ivy14();
>   ManifestHeaderElement header = new ManifestHeaderElement();
>   ModuleRevisionId resolveId = ModuleRevisionId.newInstance("", "ISO-8859-1", 
> "default", "default", header.getAttributes(), true);
>   Pack200Packing pack = new Pack200Packing();
>   String[] strings = pack.getNames();
>   ResolveReport report = ivy.resolve(resolveId, strings);
>   ResolveOptions options = new ResolveOptions();
>   report.output(new ReportOutputter[]{new XmlReportOutputter()}, 
> (ResolutionCacheManager)new DefaultResolutionCacheManager(), 
> options.setResolveId("latest-revision").setOutputReport(true));
> }
> {code}
> 
> {code}
> 1) test1(Test0)java.lang.NullPointerException
> at 
> org.apache.ivy.plugins.report.XmlReportOutputter.output(XmlReportOutputter.java:56)
> at 
> org.apache.ivy.plugins.report.XmlReportOutputter.output(XmlReportOutputter.java:47)
> at org.apache.ivy.core.report.ResolveReport.output(ResolveReport.java:106)
> at Test0.test1(Test0.java:48)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (IVY-1482) NPE in XmlReportOutputter

2016-12-11 Thread jaikiran pai (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1482?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739378#comment-15739378
 ] 

jaikiran pai commented on IVY-1482:
---

I've just submitted a pull request which adds a null check to prevent this NPE 
https://github.com/apache/ant-ivy/pull/12


> NPE in XmlReportOutputter
> -
>
> Key: IVY-1482
> URL: https://issues.apache.org/jira/browse/IVY-1482
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0-RC1
>Reporter: M Kim
>
> {code}
> public void output(ConfigurationResolveReport report, String resolveId, 
> String[] confs, ResolutionCacheManager cacheMgr) throws IOException {
>  File reportFile = 
> cacheMgr.getConfigurationResolveReportInCache(resolveId,
> report.getConfiguration());
>  File reportParentDir = reportFile.getParentFile();
>  reportParentDir.mkdirs(); // NPE
>  OutputStream stream = new FileOutputStream(reportFile);
>  writer.output(report, confs, stream);
>  stream.close();
>  //...
> }
> {code}
> In XmlReportOutputter.output method, NPE occurs when 
> reportFile.getParentFile() returns null. I think a proper error handling is 
> needed for reportFile and reportParentDir before OutputStream is created.
> 
> {code}
> public void test1() {
>   Ivy14 ivy = new org.apache.ivy.Ivy14();
>   ManifestHeaderElement header = new ManifestHeaderElement();
>   ModuleRevisionId resolveId = ModuleRevisionId.newInstance("", "ISO-8859-1", 
> "default", "default", header.getAttributes(), true);
>   Pack200Packing pack = new Pack200Packing();
>   String[] strings = pack.getNames();
>   ResolveReport report = ivy.resolve(resolveId, strings);
>   ResolveOptions options = new ResolveOptions();
>   report.output(new ReportOutputter[]{new XmlReportOutputter()}, 
> (ResolutionCacheManager)new DefaultResolutionCacheManager(), 
> options.setResolveId("latest-revision").setOutputReport(true));
> }
> {code}
> 
> {code}
> 1) test1(Test0)java.lang.NullPointerException
> at 
> org.apache.ivy.plugins.report.XmlReportOutputter.output(XmlReportOutputter.java:56)
> at 
> org.apache.ivy.plugins.report.XmlReportOutputter.output(XmlReportOutputter.java:47)
> at org.apache.ivy.core.report.ResolveReport.output(ResolveReport.java:106)
> at Test0.test1(Test0.java:48)
> {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (IVY-1499) NullPointerException while Retrieve

2016-12-11 Thread jaikiran pai (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1499?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739326#comment-15739326
 ] 

jaikiran pai commented on IVY-1499:
---

I just submitted a pull request containing a commit which checks for null to 
prevent any potential NPE https://github.com/apache/ant-ivy/pull/11


> NullPointerException while Retrieve
> ---
>
> Key: IVY-1499
> URL: https://issues.apache.org/jira/browse/IVY-1499
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0-RC1
> Environment: Hard to say:
> Worked on my System: Win 7 64, Java 6u45, Eclipse Luna and Kepler with 
> current Plugins (Ant, Ant Ivy, IvyDE, Ant Ivy Tasker)
> Occured on a very similar system and on my Test System with Lubuntu 14.04 64, 
> OpenJDK 1.7.0_65
>Reporter: Marc Meier
>Priority: Minor
>  Labels: NullPointerException
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> I encountered a NullPointerException while retrieving an ivy file. 
> Unfortunately I'm not able to recreate it properly. 
> {panel:title=Stacktrace}
> BUILD FAILED
> /var/lib/jenkins/jobs/antivy/workspace/dev/all.xml:12: The following error 
> occurred while executing this line:
> /var/lib/jenkins/jobs/antivy/workspace/dev/common_module_build.xml:74: 
> impossible to ivy retrieve: java.lang.RuntimeException: problem during 
> retrieve of org.example#org.example.converter: java.lang.NullPointerException
>   at 
> org.apache.ivy.core.retrieve.RetrieveEngine.retrieve(RetrieveEngine.java:249)
>   at org.apache.ivy.Ivy.retrieve(Ivy.java:561)
>   at org.apache.ivy.ant.IvyRetrieve.doExecute(IvyRetrieve.java:98)
>   at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:271)
>   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
>   at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:622)
>   at 
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
>   at org.apache.tools.ant.Task.perform(Task.java:348)
>   at org.apache.tools.ant.Target.execute(Target.java:435)
>   at org.apache.tools.ant.Target.performTasks(Target.java:456)
>   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
>   at 
> org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
>   at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
>   at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:440)
>   at org.apache.tools.ant.taskdefs.SubAnt.execute(SubAnt.java:306)
>   at org.apache.tools.ant.taskdefs.SubAnt.execute(SubAnt.java:221)
>   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:622)
>   at 
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
>   at org.apache.tools.ant.Task.perform(Task.java:348)
>   at org.apache.tools.ant.Target.execute(Target.java:435)
>   at org.apache.tools.ant.Target.performTasks(Target.java:456)
>   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
>   at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
>   at 
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
>   at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
>   at org.apache.tools.ant.Main.runBuild(Main.java:851)
>   at org.apache.tools.ant.Main.startAnt(Main.java:235)
>   at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
>   at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
> Caused by: java.lang.NullPointerException
>   at 
> org.apache.ivy.core.IvyPatternHelper.substituteTokens(IvyPatternHelper.java:239)
>   at 
> org.apache.ivy.core.IvyPatternHelper.substitute(IvyPatternHelper.java:171)
>   at 
> org.apache.ivy.core.retrieve.RetrieveEngine.determineArtifactsToCopy(RetrieveEngine.java:355)
>   at 
> org.apache.ivy.core.retrieve.RetrieveEngine.retrieve(RetrieveEngine.java:118)
>   ... 34 more
> {panel}
> The converter (which is the project I try to build) depends on the core, 
> which is also one of our projects. Since we only need the core for its 
> dependencies, only the ivy.xml is published in my local repository and needed 
> by the converter. 
> I tried to figure out, what the problem is. It 

[jira] [Commented] (IVY-1499) NullPointerException while Retrieve

2016-12-11 Thread ASF GitHub Bot (JIRA)

[ 
https://issues.apache.org/jira/browse/IVY-1499?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel=15739323#comment-15739323
 ] 

ASF GitHub Bot commented on IVY-1499:
-

GitHub user jaikiran opened a pull request:

https://github.com/apache/ant-ivy/pull/11

IVY-1499 Prevent potential NPE during retrieve

The commit here adds a null check to prevent a potential NPE that is 
reported in JIRA https://issues.apache.org/jira/browse/IVY-1499

You can merge this pull request into a Git repository by running:

$ git pull https://github.com/jaikiran/ant-ivy ivy-1499

Alternatively you can review and apply these changes as the patch at:

https://github.com/apache/ant-ivy/pull/11.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

This closes #11


commit c4dcddee47e560e8c768b5987fd96caffe85c673
Author: Jaikiran Pai 
Date:   2016-12-11T08:07:32Z

IVY-1499 Prevent potential NPE during retrieve




> NullPointerException while Retrieve
> ---
>
> Key: IVY-1499
> URL: https://issues.apache.org/jira/browse/IVY-1499
> Project: Ivy
>  Issue Type: Bug
>  Components: Core
>Affects Versions: 2.4.0-RC1
> Environment: Hard to say:
> Worked on my System: Win 7 64, Java 6u45, Eclipse Luna and Kepler with 
> current Plugins (Ant, Ant Ivy, IvyDE, Ant Ivy Tasker)
> Occured on a very similar system and on my Test System with Lubuntu 14.04 64, 
> OpenJDK 1.7.0_65
>Reporter: Marc Meier
>Priority: Minor
>  Labels: NullPointerException
>   Original Estimate: 1h
>  Remaining Estimate: 1h
>
> I encountered a NullPointerException while retrieving an ivy file. 
> Unfortunately I'm not able to recreate it properly. 
> {panel:title=Stacktrace}
> BUILD FAILED
> /var/lib/jenkins/jobs/antivy/workspace/dev/all.xml:12: The following error 
> occurred while executing this line:
> /var/lib/jenkins/jobs/antivy/workspace/dev/common_module_build.xml:74: 
> impossible to ivy retrieve: java.lang.RuntimeException: problem during 
> retrieve of org.example#org.example.converter: java.lang.NullPointerException
>   at 
> org.apache.ivy.core.retrieve.RetrieveEngine.retrieve(RetrieveEngine.java:249)
>   at org.apache.ivy.Ivy.retrieve(Ivy.java:561)
>   at org.apache.ivy.ant.IvyRetrieve.doExecute(IvyRetrieve.java:98)
>   at org.apache.ivy.ant.IvyTask.execute(IvyTask.java:271)
>   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
>   at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:622)
>   at 
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
>   at org.apache.tools.ant.Task.perform(Task.java:348)
>   at org.apache.tools.ant.Target.execute(Target.java:435)
>   at org.apache.tools.ant.Target.performTasks(Target.java:456)
>   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
>   at 
> org.apache.tools.ant.helper.SingleCheckExecutor.executeTargets(SingleCheckExecutor.java:38)
>   at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
>   at org.apache.tools.ant.taskdefs.Ant.execute(Ant.java:440)
>   at org.apache.tools.ant.taskdefs.SubAnt.execute(SubAnt.java:306)
>   at org.apache.tools.ant.taskdefs.SubAnt.execute(SubAnt.java:221)
>   at org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:292)
>   at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>   at 
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
>   at 
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
>   at java.lang.reflect.Method.invoke(Method.java:622)
>   at 
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
>   at org.apache.tools.ant.Task.perform(Task.java:348)
>   at org.apache.tools.ant.Target.execute(Target.java:435)
>   at org.apache.tools.ant.Target.performTasks(Target.java:456)
>   at org.apache.tools.ant.Project.executeSortedTargets(Project.java:1393)
>   at org.apache.tools.ant.Project.executeTarget(Project.java:1364)
>   at 
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
>   at org.apache.tools.ant.Project.executeTargets(Project.java:1248)
>   at org.apache.tools.ant.Main.runBuild(Main.java:851)
>   at org.apache.tools.ant.Main.startAnt(Main.java:235)
>   at org.apache.tools.ant.launch.Launcher.run(Launcher.java:280)
>   at org.apache.tools.ant.launch.Launcher.main(Launcher.java:109)
> Caused by: