* Leading spaces are lost when pulling bug #2571
Reason: during the pull (deserialization), the method `PARSE` of `ZCL_ABAPGIT_XML` does a `li_parser->set_normalizing( iv_normalize )` whose parameter has the default value "true", which strips leading and trailing spaces.
Solution: use `li_parser->add_strip_space_element( )` instead of using the normalization, which seems to work in elementary objects (clas, devc, doma, dtel, enho, enqu, fugr, intf, prog, scp1, tabl, tran, ttyp), but I fear of side effects throughout all abapGit features.
* #2571 zcl_abapgit_xml iv_normalize removed+AU
- Removal of useless parameter IV_NORMALIZE of method PARSE
- Abap Unit test added for testing the method PARSE for an XML valuecontaining leading and trailing spaces
* renaming attribute lo_xml to mo_xml
* Hotkeys no longer depend on abapGit installation
When this commit is applied hotkeys also work with
the single abapGit report. Limitation is still that users
only can override hotkeys with the installed abapGit repo.
* Fix hotkey display when no user def. hotkeys
* New: Override hotkeys within one file abapGit report
When this commit is applied it's possible to override the default
shortcut also in the one file abapGit report. It's no longer necessary
to installe the full abapGit repo to use this feature
* Extract is_merged + check in hotkey logic
* Allow access to private repos when using ADT
In case of using a private repository in ADT (aka ABAP in Eclipse), username and password are passed to the backend system. The ADT backend coding currently handles this via class ZCL_ABAPGIT_DEFAULT_AUTH_INFO. To avoid sending a password dialog in the backend system, class CL_ABAPGIT_PASSWORD_DIALOG needs to be adjusted to take over user/pw from ZCL_ABAPGIT_DEFAULT_AUTH_INFO in a generic way. I know this is not nice and it would be better to have ZCL_ABAPGIT_DEFAULT_AUTH_INFO in ZABAPGIT. Even the best solution would be to re-use ZCL_ABAPGIT_LOGIN_MANAGER instead, but I would recommend to refactor this in a new pull request later on...
* Add comment
Add comment for temporary solution and link to PR#2635
* Avoid DYNPRO_SEND_IN_BACKGROUND while ADT Pull
When ADT (aka ABAP in Eclipse) is used to trigger a pull request, there is no SAPGUI available in the backend system. Whenever a dynpro is called, a DYNPRO_SEND_IN_BACKGROUND short dump occurs.
This commit fixes issue #2632.
Additional remark: In case of a private repository, username and password are passed to the backend system. The ADT backend coding handles this via class ZCL_ABAPGIT_DEFAULT_AUTH_INFO. To avoid sending a password dialog in the backend system (class CL_ABAPGIT_PASSWORD_DIALOG), ZABAPGIT coding needs to be adjusted to take over user/pw from ZCL_ABAPGIT_DEFAULT_AUTH_INFO. I know this is not nice and it would be better to have ZCL_ABAPGIT_DEFAULT_AUTH_INFO in ZABAPGIT. Even the best solution would be to re-use ZCL_ABAPGIT_LOGIN_MANAGER, but I would recommend to refactor this in a new pull request later on...
* Fix abaplint identiation failure
Fix abaplint identiation failure
* Rest ZCL_ABAPGIT_PASSWORD_DIALOG
Rest ZCL_ABAPGIT_PASSWORD_DIALOG to prelimiary version.
To be changed in a different pull request....
* Add user exit for serialize_abap_clif_source
* Document CLIF serializer exit
* Add exit redirection for CLIF serializer
* Add link to example for CLIF serialization exit
* report name of xml file in case of format error
In case of an error in the XML file, for support reason I want to know which file causes the error. The file name is mentioned if the XML itself is corrupt or if there is an XML version mismatch.
This PR fixes issue #2619.
* fix abaplint issues
fix abaplint issues
Issue #2579: diff still shown after pull of ENHO hooks (implicit enhancements i.e. code added at start/end of existing methods, etc.)
Reason: if the author has created and deleted implicit enhancements in the original system, the numbering doesn't start from 1 (this is the numbering we can see for the statement ENHANCEMENT, for instance ENHANCEMENT 1. ... ENDENHANCEMENT.) When pulling in another system, the numbering will start from 1, so it will differ from the source. As this enhancement number is serialized by abapGit in the XML, it will detect a difference.
Correction: the method SERIALIZE of class ZCL_ABAPGIT_OBJECT_ENHO_HOOK is changed so that to not serialize the enhancement number.
Three issues are corrected:
- Enhancement events are not serialized at all, nor deserialized (missing feature).
- The codeof new enhancement methods (not the implicit enhancements of existing methods, the code for methods added) are serialized but not deserialized (incomplete feature).
- DIFF may also appear after pulling ENHO objects, concerning attributes (OTR text ID being different) and method parameters (author, date, etc.)
Corrections:
- Add serialization/deserialization of events in class ZCL_ABAPGIT_OBJECT_ENHO_CLIF
- Add deserialization of method implementations in class ZCL_ABAPGIT_OBJECT_ENHO_CLASS
- I havealso moved the existing method SERIALIZE_INCLUDES from ZCL_ABAPGIT_OBJECT_ENHO_CLIF to ZCL_ABAPGIT_OBJECT_ENHO_CLASS and created DESERIALIZE_INCLUDES in the latter class because method implementations exist only for classes, not for interfaces, so it should be done in "CLASS", not in "CLIF".
- DIFF criteria cleared in method SERIALIZE of class ZCL_ABAPGIT_OBJECT_ENHO_CLIF
#2498 Two unit tests in ZCL_ABAPGIT_GUI_PAGE_DIFF failing
It concerns two test methods which test zcl_abapgit_gui_page_diff%3D>get_patch_data. The parameter IV_PATCH is passed with an incorrect value.
This issue is due to commit 389512f690 on Feb 26, 2019
Correction of method get_patch_data_add:
- Before: |add_patch_zcl_test_git_add_p.clas.abap_19|
- After: |patch_line_add_zcl_test_git_add_p.clas.abap_0_19|
Correction of method get_patch_data_remove:
- Before: |remove_patch_ztest_patch.prog.abap_39|
- After: |patch_line_remove_ztest_patch.prog.abap_0_39|
* shortdump ZCL_ABAPGIT_ZLIB->Decompress #2483
Short dump ASSERTION_FAILED while pulling from a Git repository.
It's because of block type '00' (variable `lv_btype`) not handled at all.
00 is "non-compressed blocks", see https://www.ietf.org/rfc/rfc1951.txt section 3.2.4
The issue used to happen with Azure DevOps website, for "tree" objects (100644...) but not all tree objects.
Correction : algorithm added to handle non-compressed blocks. Test method added to complete the current test for blocks with fixed Huffman codes (01). Also one test method added for testing blocks with dynamic Huffman codes (10), test data taken from ZAZLIB.
* Lint code alignment issue
Short dump GETWA_NOT_ASSIGNED because of stupid copy/paste error in method SERIALIZE of ZCL_ABAPGIT_OBJECT_ENHO_CLIF:
LOOP AT lt_tab_types ASSIGNING <ls_type>.
CLEAR: <ls_attr>-author,
<ls_attr>-createdon,
<ls_attr>-changedby,
<ls_attr>-changedon.
ENDLOOP.
Replace all <ls_attr> with <ls_type>.
+ clearing of <ls_type>-descript_id (OTR text ID) so that the DIFF ignores this field (new OTR texts, with new IDs, are always created while pulling so the ID must not be compared).
* sfpf: make deserialization errors more verbose
Just to make debugging a little be easier.
* prog: make updating errors more verbose
For simpler debugging.
* Handle calls to repository URL on all pages
Call super class' for unhandled events in all classes displaying repository (identified from where-used list for zcl_abapgit_gui_chunk_lib%3D>render_repo_top).
I suppose it should be safe to add the 'super' call everywhere, but for now this will solve the bug.
* Revert "Merge branch 'unknown-action-url' into 'master'"
This reverts merge request !1
* Handle calls to repository URL on all pages
Call super class' for unhandled events in all classes displaying repository to handle URL click.
Relevant classes were identified by the where-used list for method render_repo_top in class zcl_abapgit_gui_chunk_lib.
I suppose it should be safe to add the 'super' call everywhere, but for now this will solve the bug.
* objects: add a method checking presence of a file
The method is called 'contains' because then you can write:
if mo_files->contains( iv_ext = 'abap' ) = abap_true.
In newer system, you can even leave out the suffix '= abap_true'.
I am not sure how to make the logic deciding how to the select
shared with the method read_file.
For future developers: if you change the type of raised exception of the
method read_file when the passed file is not found, you can stop using
the method contains and you can save some time in the cases where it is
highly unexpected that the file is missing. You could also remove the
method contains which will have the benefit of having one place with the
select statement.
* sfpf: save layout in solo XDP file
Manually tested pushing and pulling but it still might cause some
problems.
This commit adds a new file with the suffix XDP for every XFPF object.
The new file contains the form layout which can be edited in Adobe
LiveCycle Designer. During debugging I learned that we put layouts in
all supported languages to the serialized SFPF XML file but the new
layout file contains only the layout of the Form's language.
I am not sure if removing the layout data make sense because thelayout
object contains layout data for all supported languages and the call
set_layout_data changes only the form's language.
--- v2
Removed the statement:
li_fp_form->get_layout( )->set_layout_data( i_layout_data = conv #('') ).
Because it did not save any space in the SFPF XML file (because there
are layouts for other languages) and the statement instantly removes
the layout from caches and breaks forms.
--- v3
Added a check for the presence of the XDP file to make this change
backward compatible with already existing repositories where the XDP
file does not exist. Pointed out by Lars in the review.
In this version, I also "beautified" the code by a constant for the
layout file extension.
--- v4
Re-added the statement:
li_fp_form->get_layout( )->set_layout_data( i_layout_data = conv #('')
i_set_xliff_ids = abap_false ).
and added the re-cover layout data statement:
li_fp_form->get_layout( )->set_layout_data( i_layout_data = lv_layout_bck
i_set_xliff_ids = abap_false ).
The parameter i_set_xliff_ids is required by the layout type 'XFA'. It
is not possible to set layout data to an empty string without that
parameter, if you do, an exception is thrown.
The layout type 'XFA2' uses the parameter by default.
---
Closes#2554
* repo: do not validate sub-packages when ignored
In our landscape, we often need to version a package which has
sub-packages and those sub-packages have own repositories - the super
package provides framework and the sub-packages provides production
functionality.
When adding a new repository for these "framework" super-packages,
we need want to configure "Ignore sub-packages" because they are
already versioned in standalone repositories.
We also need to turn of the sub-package repo package check which is done
by this patch.
Dependency of #2395
* repo: allow creating with folder logic and ignore package
I need to enable users to add a new online repo with ignored
sub-packages and PREFIX folder logic because we often deal with
framework + implementations packages hierarchies.
Dependency of #2395
* repo: add folder logic and ign. sub.pkg to the new repo popup
This patch adds the parameters Folder logic and Ignore subpackages to
the new online repo popup to help us deal with old package which do not
follow the prefix approach for subpackages and to allow us to version
superpackages (which are shared by many developers) in separate
repositories.
I am not sure how to add a check-box to the popup window. I think I need
to find the right table with the righ column of the type char(1).
Closes#2395
* TABL: Simplify control flow
When this commit is applied the control flow in object serializer TABL
is eased. The idoc check returns now a boolean instead of raising an exception. Main purpose is to ease debugging due to reducing the use of
zcx_abapgit_exception%3D>raise.
* TABL: fill rv_deleted on early exit