Project

General

Profile

Bug #8643

ErrorManager not handling caught errors and error-status:error attribute properly

Added by Dănuț Filimon 16 days ago. Updated 16 days ago.

Status:
New
Priority:
Normal
Assignee:
-
Target version:
-
Start date:
Due date:
% Done:

0%

billable:
No
vendor_id:
GCD
case_num:

dset.xml Magnifier (747 Bytes) Dănuț Filimon, 04/17/2024 08:58 AM

raiseerror.p Magnifier (1.77 KB) Dănuț Filimon, 04/17/2024 08:59 AM

langerrorcheck.p Magnifier (1.93 KB) Dănuț Filimon, 04/17/2024 08:59 AM

ignoreerror.p Magnifier (1.81 KB) Dănuț Filimon, 04/17/2024 08:59 AM

History

#1 Updated by Dănuț Filimon 16 days ago

This issue is a continuation of #8614 that involves two problems that need to be solved. I've attached 4 files:
  • raiseerror.p
    • 4GL:
      • First error that will popup: Error reading XML file '<file>.xml'. (13035)
      • Second error that will popup: READ-XML encountered an error while parsing the XML DOcument: FATA ERROR: file '<file>.xml', line '3, column '3', message 'unterminated start tag '<tag>''. (13064)
      • Message window containing: no error raised
    • FWD:
      • First error that will popup: Error reading XML file '<file>.xml'. (13035)
      • Second error that will popup: READ-XML encountered an error while parsing the XML DOcument: FATA ERROR: file '<file>.xml', line '3', column '3', message 'Unexpected '<' character in element (missing closing '>'?) at [row,col {unknown-source}]: [3,3]'. (13064)
      • Message window containing: no error raised
  • ignoreerror.p
    • 4GL:
      • Message window containing: no Error reading XML file '<file>.xml'. (13035)
    • FWD:
      • Message window containing: yes Error reading XML file '<file>.xml'. (13035)
  • langerrorcheck.p
    • 4GL:
      • Message window containing 2 errors: Error reading XML file '<file>.xml'. (13035) and READ-XML encountered an error while parsing the XML DOcument: FATA ERROR: file '<file>.xml', line '3, column '3', message 'unterminated start tag '<tag>''. (13064)
    • FWD:
      • Message window that contains only 1 error: Error reading XML file '<file>.xml'. (13035)
  • dset.xml: an invalid xml file (has a deleted '>')
    • Needs to be placed in deploy/client/ when working with the first 3 files mentioned.
    • Alternatively, it is possible to uncomment the RUN write-schema from the .p files, convert, run the test to create dset.xml and make it invalid by deleting a tag then reconvert without RUN write-schema to not override it.

These FWD scenarios are only obtainable with the fix from 8614a branch.

There are three objectives for this issue:
  1. ignoreerror.p displays error-status:error as no in 4GL and yes in FWD. I tried to use ErrorManager.recordOrShowError with isError flag set to false but this breaks langerrorcheck.p because instead of the message window, it display an error popup which is not correct;
  2. langerrorcheck.p only shows the first error in FWD because in ErrorManager.recordOrShowError() line 1205 it sets manageLegacyError to true and throws a DefferedLegacyErrorException at line 1242. This results in a single error being thrown and caught;
  3. similar to DATASET, test READ-XML for TEMP-TABLE.

#3 Updated by Greg Shah 16 days ago

  • Project changed from Runtime Infrastructure to Base Language

Also available in: Atom PDF