Don't fail if a dictionary object is activated with warnings (#5362)

* Fix proposal for issue #5347: added support for 'TYPE REF TO DATA' DDIC data elements as components in DDIC structures

* Fix proposal for issue #5347. Added support for 'REF TO DATA' DTEL DDIC element residing in DDIC structure

* Fix proposal for issue #5347, added support for 'TYPE REF TO DATA' DDIC data element residing in DDIC data structurees

* REF TO DATA for DDIC element support (#5347)

* No error if ddic type has warning (abapGit#5361) during import

* Update zcl_abapgit_objects_activation.clas.abap

* Fix for (abapGit#5361). Warnings during DDIC objects activation shouldn't be considered as error but will be shown as 'yellow' messages after activation

* Fix for (#5361).
Warnings during DDIC objects activation shouldn't be considered as error but will be shown as 'yellow' messages after activation

Co-authored-by: Lars Hvam <larshp@hotmail.com>
This commit is contained in:
Alexandr Razinkin 2022-02-20 13:39:09 +03:00 committed by GitHub
parent 91cd4c3653
commit 353f748bd6
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -65,7 +65,7 @@ CLASS zcl_abapgit_objects_activation DEFINITION
!ii_log TYPE REF TO zif_abapgit_log
RAISING
zcx_abapgit_exception .
CLASS-METHODS add_errors_to_log
CLASS-METHODS add_errors_and_warnings_to_log
IMPORTING
!iv_logname TYPE ddmass-logname
!ii_log TYPE REF TO zif_abapgit_log
@ -164,9 +164,12 @@ CLASS zcl_abapgit_objects_activation IMPLEMENTATION.
ENDIF.
IF lv_rc > 0.
add_errors_to_log(
add_errors_and_warnings_to_log(
iv_logname = lv_logname
ii_log = ii_log ).
ENDIF.
IF lv_rc > 4.
zcx_abapgit_exception=>raise( 'Activation cancelled. Check the inactive objects.' ).
ENDIF.
@ -280,7 +283,7 @@ CLASS zcl_abapgit_objects_activation IMPLEMENTATION.
ENDMETHOD.
METHOD add_errors_to_log.
METHOD add_errors_and_warnings_to_log.
DATA: lt_lines TYPE STANDARD TABLE OF trlog,
lv_logname_db TYPE ddprh-protname.
@ -306,12 +309,14 @@ CLASS zcl_abapgit_objects_activation IMPLEMENTATION.
ENDIF.
" Only error messsages
DELETE lt_lines WHERE severity <> 'E'.
DELETE lt_lines WHERE severity <> 'E'
AND severity <> 'W'.
" Remove "Return code..." message
DELETE lt_lines WHERE class = 'D0' AND number = '319'.
LOOP AT lt_lines ASSIGNING <ls_line>.
ii_log->add( <ls_line>-line ).
ii_log->add( iv_msg = <ls_line>-line
iv_type = <ls_line>-severity ).
ENDLOOP.
ENDMETHOD.