Bug 731982 - XMLRPC: Product should not be required when updated TestRun's build
Summary: XMLRPC: Product should not be required when updated TestRun's build
Keywords:
Status: VERIFIED
Alias: None
Product: TCMS
Classification: Other
Component: Application
Version: 3.5
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 3.8.0
Assignee: Yang Ren
QA Contact: Nobody
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-08-19 11:14 UTC by Petr Šplíchal
Modified: 2022-03-14 03:25 UTC (History)
4 users (show)

Fixed In Version: 3.8.0-1
Clone Of:
Environment:
Last Closed:
Embargoed:


Attachments (Terms of Use)

Description Petr Šplíchal 2011-08-19 11:14:43 UTC
Description of problem:

When trying to update a TestRun's build I see the following
traceback:

    >>> TestRun.update(6757, {'build': 1398 })
    Traceback (most recent call last):
    File "<stdin>", line 1, in <module>
    File "/usr/lib64/python2.6/xmlrpclib.py", line 1199, in __call__
        return self.__send(self.__name, args)
    File "/usr/lib64/python2.6/xmlrpclib.py", line 1489, in __request
        verbose=self.__verbose
    File "nitrate.py", line 120, in request_with_cookies
        return self._parse_response(h.getfile(), sock)
    File "/usr/lib64/python2.6/xmlrpclib.py", line 1392, in _parse_response
        return u.close()
    File "/usr/lib64/python2.6/xmlrpclib.py", line 838, in close
        raise Fault(**self._stack[0])
    xmlrpclib.Fault: <Fault 1: 'ValueError: Field "product" is
    required by build or product_version'>

Product is a foreign key of the build, there is no product id in
the TestRun itself, so requiring product id does not make sense.
Please remove this limitation as it causes unnecesary build data
fetching.

Version-Release number of selected component (if applicable):
3.5.0

Comment 1 jianchen 2012-06-14 08:35:57 UTC
Fixed in tcms 3.8.0, please verify after release.
Product id was not required when use TestRun.update() method update build.

Comment 2 Xin Gao 2012-07-26 02:57:05 UTC
Verify 3.8.0-1 on stage -->PASS

Verify steps:
1.test TestRun.update() method update build.
such as, 
$ n.TestRun.update(6757, {'build': 1398 })


Actual result:
works well.


Note You need to log in before you can comment on or make changes to this bug.