Dan Kenigsberg has submitted this change and it was merged.

Change subject: lib: api.py: preserve signature in decorator
......................................................................


lib: api.py: preserve signature in decorator

The api.method decorator needs to preserve the function
or method signature, to let the schema validation keep working.
Moreover, preserving the signature of decorated callables
is a good idea anyway.

In python 3.4+ this is done by default, but on python 2.7
we need to take steps to implement this.
We leverage the existing 'decorator' module which solves
this problem. This module is available in EL/Centos7.

For further reference:
http://pythonhosted.org/decorator/documentation.html

Change-Id: I06205cf180229ea19ffc38a7b88346afc18f13e4
Signed-off-by: Francesco Romani <from...@redhat.com>
Reviewed-on: https://gerrit.ovirt.org/63759
Reviewed-by: Nir Soffer <nsof...@redhat.com>
Reviewed-by: Piotr Kliczewski <piotr.kliczew...@gmail.com>
Continuous-Integration: Jenkins CI
Reviewed-by: Dan Kenigsberg <dan...@redhat.com>
---
M automation/build-artifacts.packages.el7
M automation/build-artifacts.packages.fc24
M automation/check-merged.packages.el7
M automation/check-merged.packages.fc24
M automation/check-patch.packages.el7
M automation/check-patch.packages.fc24
M lib/vdsm/common/api.py
M tests/api_test.py
M vdsm.spec.in
9 files changed, 55 insertions(+), 20 deletions(-)

Approvals:
  Piotr Kliczewski: Looks good to me, but someone else must approve
  Nir Soffer: Looks good to me, but someone else must approve
  Jenkins CI: Passed CI tests
  Dan Kenigsberg: Looks good to me, approved
  Francesco Romani: Verified



-- 
To view, visit https://gerrit.ovirt.org/63759
To unsubscribe, visit https://gerrit.ovirt.org/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I06205cf180229ea19ffc38a7b88346afc18f13e4
Gerrit-PatchSet: 14
Gerrit-Project: vdsm
Gerrit-Branch: master
Gerrit-Owner: Francesco Romani <from...@redhat.com>
Gerrit-Reviewer: Dan Kenigsberg <dan...@redhat.com>
Gerrit-Reviewer: Francesco Romani <from...@redhat.com>
Gerrit-Reviewer: Irit Goihman <igoih...@redhat.com>
Gerrit-Reviewer: Jenkins CI
Gerrit-Reviewer: Milan Zamazal <mzama...@redhat.com>
Gerrit-Reviewer: Nir Soffer <nsof...@redhat.com>
Gerrit-Reviewer: Piotr Kliczewski <piotr.kliczew...@gmail.com>
Gerrit-Reviewer: gerrit-hooks <automat...@ovirt.org>
_______________________________________________
vdsm-patches mailing list -- vdsm-patches@lists.fedorahosted.org
To unsubscribe send an email to vdsm-patches-le...@lists.fedorahosted.org

Reply via email to