Bug 32658 - univention-install-config-registry ignores error code of univention-install-config-registry-info
univention-install-config-registry ignores error code of univention-install-c...
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: UCR
UCS 5.0
Other Linux
: P5 normal (vote)
: UCS 5.0
Assigned To: Philipp Hahn
Florian Best
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2013-09-20 14:16 CEST by Philipp Hahn
Modified: 2021-05-25 16:02 CEST (History)
2 users (show)

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Philipp Hahn univentionstaff 2013-09-20 14:16:49 CEST
# univention-install-config-registry-info ; echo $?
Incomplete entries in variable definition univention-base-files.univention-config-registry-variables
  ipv6/gateway:
    type
1
# univention-install-config-registry ; echo $?
0


diff --git a/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/debian/changelog b/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/debian/changelog
index 316f2b6..d97d491 100644
--- a/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/debian/changelog
+++ b/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/debian/changelog
@@ -1,3 +1,9 @@
+univention-config-registry (9.0.4-3) unstable; urgency=low
+
+  * Abort on error during univention-install- (Bug #)
+
+ -- Philipp Hahn <hahn@univention.de>  Fri, 20 Sep 2013 14:11:34 +0200
+
 univention-config-registry (9.0.4-2) unstable; urgency=low
 
   * Undo r43985 (Bug #32544)
diff --git a/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/python/univention-install-config-registry b/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/python/univention-install-config-registry
index 952ab43..1c2493d 100755
--- a/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/python/univention-install-config-registry
+++ b/branches/ucs-3.2/ucs-3.2-0/base/univention-config-registry/python/univention-install-config-registry
@@ -165,6 +165,7 @@ def do_package(package):
 
        doIt('perl', '-e', 'use Debian::Debhelper::Dh_Lib;addsubstvar("%s", "misc:Depends", "univention-config (>= 7.0.25)");' % package)
 
+
 def main():
        """Install config registry script."""
        usage = "%prog"
@@ -199,8 +200,12 @@ The mapping files debian/*.univention-config-registry-mapping go to /etc/univent
                print >> sys.stderr, ex
                sys.exit(1)
 
-       doIt("univention-install-config-registry-info")
-       doIt("univention-install-service-info")
+       for prog in ("univention-install-config-registry-info", "univention-install-service-info"):
+               ret = doIt(prog)
+               if ret:
+                       print >> sys.stderr, "Error: %s returned %d" % (prog, ret)
+                       sys.exit(ret)
+
 
 if __name__ == '__main__':
        main()
Comment 1 Florian Best univentionstaff 2017-02-10 10:20:55 CET
Still broken.
Comment 2 Ingo Steuwer univentionstaff 2020-07-03 20:55:28 CEST
This issue has been filed against UCS 4.2.

UCS 4.2 is out of maintenance and many UCS components have changed in later releases. Thus, this issue is now being closed.

If this issue still occurs in newer UCS versions, please use "Clone this bug" or reopen it and update the UCS version. In this case please provide detailed information on how this issue is affecting you.
Comment 3 Philipp Hahn univentionstaff 2020-07-05 19:04:01 CEST
Finally fix it instead:

[feature/ucs5] b7145d5255 Bug #32658 UCR: Abort on error during univention-install-*
 base/univention-config-registry/debian/changelog                   | 1 +
 .../python/univention-install-config-registry                      | 7 +++++--
 doc/changelog/changelog-5.0-0.xml                                  | 4 ++++
 3 files changed, 10 insertions(+), 2 deletions(-)
Comment 4 Florian Best univentionstaff 2020-07-06 14:15:47 CEST
OK: broken entries break the package build now:

Error: univention-install-config-registry-info returned 1
make[1]: *** [debian/rules:37: override_dh_auto_install] Error 1
make[1]: Leaving directory '/root/build/univention-base-files'
make: *** [debian/rules:34: binary] Error 2
dpkg-buildpackage: error: debian/rules binary subprocess returned exit status 2

OK: changelog
Comment 5 Florian Best univentionstaff 2021-05-25 16:02:54 CEST
UCS 5.0 has been released:
 https://docs.software-univention.de/release-notes-5.0-0-en.html
 https://docs.software-univention.de/release-notes-5.0-0-de.html

If this error occurs again, please use "Clone This Bug".