Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pull: new XSLT object is not activated before program, and so makes program activation fail #5262

Closed
sandraros opened this issue Jan 10, 2022 · 16 comments
Labels
bug Something isn't working

Comments

@sandraros
Copy link
Contributor

Programs which refer statically to new transformation objects can't be activated because the transformation has not been activated.

abapGit 1.114.0
ABAP 7.52 SP 0

While pulling https://github.com/abap2xlsx/abap2xlsx which contains the new transformation object ZEXCEL_TR_DOCPROPS_CORE, I get this error:

First mention of the activation issue (NB: in this list of inactive objects, I don't see the new transformation object):
image

Details of the syntax errors:
image

We see the transformation is currently inactive:
Transaction STRANS showing ST transformation

I activated the transformation:
activated the transformation

After that, I can continue the activation of other objects.

@larshp
Copy link
Member

larshp commented Jan 10, 2022

thanks, it might be a regression from #5198

first step, try adding another unit test in https://github.com/abapGit/abapGit/blob/main/src/objects/core/zcl_abapgit_file_deserialize.clas.testclasses.abap for XSLT and PROG

@larshp
Copy link
Member

larshp commented Jan 12, 2022

sequence seems okay, at least according to the unit test added in #5268

@larshp
Copy link
Member

larshp commented Jan 12, 2022

#5003 is relevant

seems like we want XSLT to activate both before and after PROG/CLAS, any way to force it active or activate along with PROG/CLAS?

@larshp larshp added the bug Something isn't working label Jan 12, 2022
@sandraros
Copy link
Contributor Author

sandraros commented Jan 12, 2022

For information, I have created the branch issue-5262 in this repository to contain all known test cases for XSLT, to extend your test repository. Feel free to do whatever you want with it.

@larshp
Copy link
Member

larshp commented Jan 12, 2022

@sandraros cool, I've invited you to the https://github.com/abapGit-tests organization, so you should now have access to create repositories there. More repositories with small testcases is good

Perhaps try setting I_SOURCE_STATE to active when calling save(),
image

@sandraros
Copy link
Contributor Author

Thanks, I will work on it in 2 hours.

@mbtools
Copy link
Member

mbtools commented Jan 12, 2022

Tested with https://github.com/sandraros/abapgit-reproduce-issue-5262. Works flawlessly:

SAPgui_537

XSLTs are processed twice: first in step "ABAP". They are therefore activated together with PROGs. If an XSLT depends on other objects, it won't activate. Therefore, XSLTs are activated again in the "LATE" step.

In my test, I used the "Activate without showing popup" setting, so there are no activate popups. Without the setting, you will get two popups but it activates the XSLTs properly, too.

In short, the test repo is not sufficient to reproduce the issue you mentioned initially.

@sandraros
Copy link
Contributor Author

sandraros commented Jan 12, 2022

Could you try without using the "Activate without showing popup" setting? Without this setting, you get the popup described in the issue ("Activate despite errors"). If you click "Activate", it will activate, but if you click "Edit", you see the syntax errors.

@sandraros
Copy link
Contributor Author

Maybe the difference is because I use 7.52 SP 0 ?

@mbtools
Copy link
Member

mbtools commented Jan 12, 2022

here's the recording without the setting (7.50 SP 21):

SAPgui_539

I know the kind of "Activate/Edit/Cancel" popup, but I'm not getting that. I will test on 7.54 tomorrow.

@sandraros
Copy link
Contributor Author

This is what I get in 7.52 SP 1 / kernel 753 SP 500 :
abapgit-issue-5262

larshp added a commit that referenced this issue Jan 13, 2022
@mbtools
Copy link
Member

mbtools commented Jan 13, 2022

Test on 7.54 SP 2 (current ABAP 1909 Dev Edition, Kernel 777 patch 200)... It works exactly the same as my 7.50 test, with or without the setting.

Some corrections must be missing in your system. I found the SAP Note... (we should have looked earlier):

2859159 - XSLT: Support dependencies on inactive objects
https://launchpad.support.sap.com/#/notes/2859159

@sandraros
Copy link
Contributor Author

Thanks for investigating. I guess it must be the error, and I propose to close the issue if you agree. Thanks again!

@AndreaBorgia-Abo
Copy link
Member

For curiosity I had a look on my own demo systems as well:

  • 7.52SP04 still complains (kernel 753)
  • HANA1909 works fine
    I've tried uploading SAR files to install the notes (2859159 and dependents), but 2859159 itself does not meet the kernel requirements: I have 400, minimum is 521, bummer!

Oh, unrelated question: what did you guys use for making the animated gif above?

@sandraros
Copy link
Contributor Author

Trial version 7.52 SP 1 has kernel 753 SP 500. It's fixed with the note above + you need 753 SP 521, 773 SP 230 or 777 SP 36.
ScreenToGif.

@mbtools
Copy link
Member

mbtools commented Jan 15, 2022

I'm using ShareX. Love it. Free, too

https://getsharex.com/

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Development

No branches or pull requests

4 participants