Openbravo Issue Tracking System - Openbravo ERP
View Issue Details
0053215Openbravo ERPZ. Otherspublic2023-08-14 15:252023-08-17 12:37
aferraz 
fermin_gascon 
normalminorhave not tried
closedfixed 
5
 
PR23Q4 
caristu
Core
pi
No
0053215: ReducedTranslationExportTests test failure
The problem is in the test ReducedTranslationExportTests when calling org.openbravo.service.db.CallProcess.callProcess() This method requires now Weld to be initiated in order to execute extension hooks.

The stacktrace of executing this test is the following:
java.lang.IllegalStateException: java.lang.NullPointerException
    at org.openbravo.service.db.CallProcess.callProcess(CallProcess.java:223)
    at org.openbravo.service.db.CallProcess.call(CallProcess.java:121)
    at org.openbravo.service.db.CallProcess.call(CallProcess.java:97)
    at org.openbravo.service.db.CallProcess.call(CallProcess.java:255)
    at org.openbravo.test.reducedtranslation.ReducedTranslationExportTests.doVerifyLanguageIfNotPreviouslyDoneBefore(ReducedTranslationExportTests.java:68)
    at org.openbravo.test.reducedtranslation.ReducedTranslationExportTests.exportReducedTranslation(ReducedTranslationExportTests.java:56)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at org.jboss.arquillian.junit.Arquillian$StatementLifecycleExecutor.invoke(Arquillian.java:378)
    at org.jboss.arquillian.container.test.impl.execution.ClientBeforeAfterLifecycleEventExecuter.execute(ClientBeforeAfterLifecycleEventExecuter.java:88)
    at org.jboss.arquillian.container.test.impl.execution.ClientBeforeAfterLifecycleEventExecuter.on(ClientBeforeAfterLifecycleEventExecuter.java:57)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
    at org.jboss.arquillian.core.impl.EventContextImpl.invokeObservers(EventContextImpl.java:103)
    at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:90)
    at org.jboss.arquillian.test.impl.TestContextHandler.createClassContext(TestContextHandler.java:83)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
    at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
    at org.jboss.arquillian.test.impl.TestContextHandler.createSuiteContext(TestContextHandler.java:69)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at org.jboss.arquillian.core.impl.ObserverImpl.invoke(ObserverImpl.java:86)
    at org.jboss.arquillian.core.impl.EventContextImpl.proceed(EventContextImpl.java:95)
    at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:133)
    at org.jboss.arquillian.core.impl.ManagerImpl.fire(ManagerImpl.java:105)
    at org.jboss.arquillian.test.impl.EventTestRunnerAdaptor.beforeClass(EventTestRunnerAdaptor.java:89)
    at org.jboss.arquillian.junit.Arquillian$2.evaluate(Arquillian.java:163)
    at org.jboss.arquillian.junit.Arquillian.multiExecute(Arquillian.java:350)
    at org.jboss.arquillian.junit.Arquillian.access$200(Arquillian.java:54)
    at org.jboss.arquillian.junit.Arquillian$3.evaluate(Arquillian.java:177)
    at org.jboss.arquillian.junit.Arquillian.run(Arquillian.java:115)
    at jdk.internal.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
    at jdk.internal.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
    at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
Caused by: java.lang.NullPointerException
    at org.openbravo.base.weld.WeldUtils.getStaticInstanceBeanManager(WeldUtils.java:55)
    at org.openbravo.base.weld.WeldUtils.getInstances(WeldUtils.java:149)
    at org.openbravo.base.weld.WeldUtils.getInstancesSortedByPriority(WeldUtils.java:174)
    at org.openbravo.service.db.CallProcess.getHooks(CallProcess.java:299)
    at org.openbravo.service.db.CallProcess.callProcess(CallProcess.java:218)
See the following CI job:
https://builds.openbravo.com/view/modules/job/mod-translations/1367/ [^]

No tags attached.
caused by feature request 0050364 closed fermin_gascon It will be nice to have and api to export goods receipts and shipments to external services 
Issue History
2023-08-14 15:25aferrazNew Issue
2023-08-14 15:25aferrazAssigned To => Triage Platform Conn
2023-08-14 15:25aferrazModules => Core
2023-08-14 15:25aferrazRegression introduced in release => pi
2023-08-14 15:25aferrazTriggers an Emergency Pack => No
2023-08-14 15:25aferrazRelationship addedcaused by 0050364
2023-08-14 15:53adrianromeroSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=26642#r26642
2023-08-14 15:57adrianromeroDescription Updatedbug_revision_view_page.php?rev_id=26644#r26644
2023-08-14 15:57adrianromeroSteps to Reproduce Updatedbug_revision_view_page.php?rev_id=26645#r26645
2023-08-17 12:36hgbotResolutionopen => fixed
2023-08-17 12:36hgbotStatusnew => resolved
2023-08-17 12:36hgbotFixed in Version => PR23Q4
2023-08-17 12:36hgbotNote Added: 0153583
2023-08-17 12:37caristuReview Assigned To => caristu
2023-08-17 12:37caristuStatusresolved => closed
2023-08-17 12:37caristuAssigned ToTriage Platform Conn => fermin_gascon
2023-08-17 12:37caristuNote Added: 0153585

Notes
(0153583)
hgbot   
2023-08-17 12:36   
Repository: https://gitlab.com/openbravo/product/openbravo [^]
Changeset: 5b4f0ea40e9ecf6aa9df4b2e4d00cf026f5967e2
Author: Fermín Gascón <fermin.gascon@openbravo.com>
Date: 17-08-2023 10:36:56
URL: https://gitlab.com/openbravo/product/openbravo/-/commit/5b4f0ea40e9ecf6aa9df4b2e4d00cf026f5967e2 [^]

Fixed ISSUE-53215: fix test by executing CallProcess after Weld has been initialized

---
M src-test/src/org/openbravo/test/reducedtranslation/ReducedTranslationExportTests.java
---
(0153585)
caristu   
2023-08-17 12:37   
MR: https://gitlab.com/openbravo/product/openbravo/-/merge_requests/971 [^]