Cross repository syntax check before merge
When developing ABAP code, there are two approaches for referencing dependencies,
A: Copy/duplicate the code. Discover syntax errors or bugs when the corresponding pull request is opened. Check the blog post “Automagic standalone renaming of ABAP objects” for a description of this setup.
B: Static references
This blog post deals with scenario “B”, where multiple developers works across multiple repositories building a statically referenced application.
It is only possible to have one active version of an object in an ABAP system, and code must evolve, not always staying backwards compatible.
This can give syntax errors in repositories referencing changed code, in order to mitigate this, its now possible to automatically perform cross repository syntax checks before merging using abaplint.
Say, for the example diagram below, a pull request is opened in “Repository 1”, this will trigger 3 syntax checks,
- Repository A, branch “main”
- Repository B, branch “main”
- Repository B, branch “branch1”
Against the code in the branch of the pull request. This gives early feedback to developers, giving the possibility of fixing issues before they hit “main”.
Real life example
Pull request https://github.com/abapGit/abapGit/pull/5503 removes objects used in https://github.com/abapGit/background_modes/
An error was discovered and reported in https://github.com/abapGit/abapGit/runs/6229402584
Successfully mitigated by Marc Bernard before merge 😊
As always, from 702 and up, try it out today 🤠