•  
      request #7419 Error 500 on POST /artifacts or PUT /artifacts/123 when status field not empty
    Infos
    #7419
    Laurent Delaigue (ldelaigue)
    2014-10-01 09:45
    2014-09-05 16:54
    7421
    Details
    Error 500 on POST /artifacts or PUT /artifacts/123 when status field not empty
    When creating a new milestone or updating it, I get an error 500 if its status field os not empty at the creation, or if I change its status field from empty to some value.

    Here is the JSON sent for the creation:

    POST /api/v1/artifacts
    body:
    {"values":[{"field_id":1146,"value":""},{"field_id":1149,"bind_value_ids":[1030]},{"field_id":1152,"value":"0"},{"field_id":1147,"value":""},{"field_id":1150,"value":"0"},{"field_id":1144,"value":"lambda 1"},{"field_id":1154,"links":[]}],"tracker":{"id":35}}

    And here is what's in the server logs:

    [Fri Sep 05 14:36:19 2014] [error] [client 192.168.30.113] PHP Fatal error: Call to undefined function permission_is_authorized() in /usr/share/codendi/plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_List.class.php on line 1211

    API
    7.2
    Empty
    • [ ] enhancement
    • [ ] internal improvement
    Patricia Carrasco (pcar)
    Stage
    Hugo KELFANI (hkelf)
    Closed
    2014-09-22
    Attachments
    References

    Follow-ups

    User avatar

    Hello Laurent,

    I've got several questions in order to reproduce the issue:

    • Which is the traker of your artifact 317 ?
    • Do you modify after the creation of the artifact 317 the tracker structure ?
    User avatar
    Done Hugo,
    it's request #7474

    I'm wondering though, is it normal that I could create an artifact without a status?
    i'm not sure but I believe there is a workflow defined on my status field. In this case, the server should have set the status to the first value in the workflow, shouldn't it?
    User avatar
    Hugo KELFANI (hkelf)2014-09-24 09:29
    Hi Laurent,

    This seems to be an other bug. I'm working on it.
    Could you open a second ticket ?
    User avatar
    Hi Manuel,

    Unfortunately it seems to be only partially fixed.
    I upgraded Tuleap to 7.5.99.8 and got the following error when I tried to update an artifact created without any status:


    PUT /api/v1/artifacts/317
    body:
    {"values":[{"field_id":1064,"bind_value_ids":[963]},{"field_id":1068,"value":"Other Epic for 127"},{"field_id":1084,"links":[]},{"field_id":1060,"bind_value_ids":[958]},{"field_id":1065,"bind_value_ids":[102]},{"field_id":1069,"value":""},{"field_id":1061,"value":"0"},{"field_id":1062,"bind_value_ids":[]},{"field_id":1070,"value":""},{"bind_value_ids":[],"field_id":1073}]}
    __________
    response:
    HTTP/1.0 500 Internal Server Error


    and on the Tuleap server error_log file:

    [Mon Sep 22 17:19:03 2014] [error] [client 192.168.30.113] PHP Fatal error: Call to a member function getId() on a non-object in /usr/share/codendi/plugins/tracker/include/Tracker/FormElement/Tracker_FormElement_Field_List.class.php on line 655
    User avatar
    Review gerrit #3032
    Merged in Tuleap 7.5.99.8

    Laurent, do you confirm it's fixed now ?

    • Status changed from New to Closed
    • Assigned to changed from None to Hugo KELFANI (hkelf)
    • Close date set to 2014-09-22