Minor issue with the code

Bug #1546878 reported by deray
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
proliantutils
Fix Released
Undecided
kesper

Bug Description

There is an issue with the code raising the exception, InvalidInputError, here:

    https://github.com/openstack/proliantutils/blob/master/proliantutils/hpssa/manager.py#L133

Invalid::

    raise exception.InvalidInputError(reason=msg)

This would give the result as:

    TypeError: InvalidInputError does not take keyword arguments

Whereas the intended and valid way should be::

    raise exception.InvalidInputError(msg)

Or, modify the code of InvalidInputError custom exception constructor to accept keyword arguments to accommodate such invocation.

deray (debayan-ray)
Changed in proliantutils:
status: New → In Progress
kesper (paresh-h-sao)
Changed in proliantutils:
assignee: nobody → kesper (paresh-h-sao)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to proliantutils (master)

Reviewed: https://review.openstack.org/328904
Committed: https://git.openstack.org/cgit/openstack/proliantutils/commit/?id=32a1cc26f834af5faba76843cdd9fc4391c552f0
Submitter: Jenkins
Branch: master

commit 32a1cc26f834af5faba76843cdd9fc4391c552f0
Author: kesper <email address hidden>
Date: Mon Jun 13 11:24:05 2016 +0530

    Adds constructor for InvalidInputError

    This change allows keyword arguments to constructor of
    InvalidInputError exception. And supports the use of ``reason``
    as well as user-defined arguments as part of the error message.

    Closes-bug: #1546878
    Co-Authored-By: Debayan Ray <email address hidden>
    Change-Id: I99d901b58e45a90be128f1006a447ce69ebe91a1

Changed in proliantutils:
status: In Progress → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.