Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0008358Openbravo ERPA. Platformpublic2009-03-31 12:142009-04-29 00:00
marvintm 
alostale 
normalmajorhave not tried
closedfixed 
5
main 
2.50MP1 
Core
No
0008358: When package.module is called without having exported the module, the process crashes without any meaningful message
When package.module is called without having exported the module, the process crashes (because it tries to zip a non-existent directory) without any message, only with a NullPointerException:

openbravo@domU-12-31-39-03-4A-44 AppsOpenbravo]$ ant package.module
> -Dmodule=com.mycompany.hotel
> Buildfile: build.xml
>
> package.module:
> [echo] Validating Module...
> [validateModules] 0 [main] WARN SystemValidation - Validation
> successfull no warnings or errors
>
> obx.export.database:
>
> obx.export.config.script:
> [extractModule] java.lang.NullPointerException
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModule.createOBX(ExtractModule.java:203)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModule.extractModule(ExtractModule.java:156)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModule.extractPackage(ExtractModule.java:175)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModule.extract(ExtractModule.java:86)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModule.extractName(ExtractModule.java:141)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModuleTask.doExecute(ExtractModuleTask.java:64)
> [extractModule] at
> org.openbravo.erpCommon.modules.ExtractModuleTask.execute(ExtractModuleTask.java:44)
> [extractModule] at
> org.apache.tools.ant.UnknownElement.execute(UnknownElement.java:288)
> [extractModule] at
> sun.reflect.GeneratedMethodAccessor91.invoke(Unknown Source)
> [extractModule] at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
> [extractModule] at java.lang.reflect.Method.invoke(Method.java:597)
> [extractModule] at
> org.apache.tools.ant.dispatch.DispatchUtils.execute(DispatchUtils.java:106)
> [extractModule] at org.apache.tools.ant.Task.perform(Task.java:348)
> [extractModule] at
> org.apache.tools.ant.Target.execute(Target.java:357)
> [extractModule] at
> org.apache.tools.ant.Target.performTasks(Target.java:385)
> [extractModule] at
> org.apache.tools.ant.Project.executeSortedTargets(Project.java:1337)
> [extractModule] at
> org.apache.tools.ant.Project.executeTarget(Project.java:1306)
> [extractModule] at
> org.apache.tools.ant.helper.DefaultExecutor.executeTargets(DefaultExecutor.java:41)
> [extractModule] at
> org.apache.tools.ant.Project.executeTargets(Project.java:1189)
> [extractModule] at org.apache.tools.ant.Main.runBuild(Main.java:758)
> [extractModule] at org.apache.tools.ant.Main.startAnt(Main.java:217)
> [extractModule] at
> org.apache.tools.ant.launch.Launcher.run(Launcher.java:257)
> [extractModule] at
> org.apache.tools.ant.launch.Launcher.main(Launcher.java:104)
>

Of course, the process cannot complete succesfully if the module has not been exported, but a meaningful message should be provided, so the user knows that he needs to export the module (or call package.module with -Dobx.export.DB=true)
main
has duplicate defect 0008939 closed alostale Null Pointer Exception at packaging a Industry template 
Issue History
2009-03-31 12:14marvintmNew Issue
2009-03-31 12:14marvintmAssigned To => alostale
2009-03-31 12:14marvintmRegression testing => No
2009-04-01 09:53pjuvaraversion => main
2009-04-03 09:17hgbotCheckin
2009-04-03 09:17hgbotNote Added: 0015146
2009-04-03 09:17hgbotStatusnew => resolved
2009-04-03 09:17hgbotResolutionopen => fixed
2009-04-03 09:17hgbotFixed in SCM revision => http://code.openbravo.com/erp/devel/pi/rev/500bea73b740486e7c44650744d386d3bbf04935 [^]
2009-04-22 11:24psarobeTag Attached: main
2009-04-28 20:20psarobeStatusresolved => closed
2009-04-29 00:00anonymoussf_bug_id0 => 2783258
2009-05-08 12:35alostaleRelationship addedhas duplicate 0008939

Notes
(0015146)
hgbot   
2009-04-03 09:17   
Repository: erp/devel/pi
Changeset: 500bea73b740486e7c44650744d386d3bbf04935
Author: Asier Lostalé <asier.lostale <at> openbravo.com>
Date: Fri Apr 03 09:16:54 2009 +0200
URL: http://code.openbravo.com/erp/devel/pi/rev/500bea73b740486e7c44650744d386d3bbf04935 [^]

fixed bug 0008358: When package.module is called without having exported the module, the process crashes without any meaningful message

---
M src/org/openbravo/erpCommon/modules/ExtractModule.java
---