#50663 Issue 50634 - Clean up CLI errors output - Fix wrong exception
Closed 3 years ago by spichugi. Opened 4 years ago by spichugi.
spichugi/389-ds-base fix-exception-log-cleanup  into  master

@@ -423,6 +423,6 @@ 

      errmsg = str(exception)

      try:

          msg = ast.literal_eval(errmsg)

-     except ValueError:

+     except Exception:

          msg = {'desc': errmsg}

      return msg

Description: The previous commit takes care only about ValueError
evaluation. But it is possible that other exceptions will be raised
which will result in a wrong error output.
Make the exception object more general.

https://pagure.io/389-ds-base/issue/50634

Reviewed by: ?

Thank you, @mhonek , for the fast reporting!

Pull-Request has been merged by spichugi

4 years ago

389-ds-base is moving from Pagure to Github. This means that new issues and pull requests
will be accepted only in 389-ds-base's github repository.

This pull request has been cloned to Github as issue and is available here:
- https://github.com/389ds/389-ds-base/issues/3718

If you want to continue to work on the PR, please navigate to the github issue,
download the patch from the attachments and file a new pull request.

Thank you for understanding. We apologize for all inconvenience.

Pull-Request has been closed by spichugi

3 years ago
Metadata