Mantis Bugtracker          
testlink.org

View Issue Details Jump to Notes ] Issue History ] Print ]
IDProjectCategoryView StatusDate SubmittedLast Update
0008660TestLinkAPI - XMLRPCpublic2019-05-09 20:142019-05-28 18:26
Reporterlczub 
Assigned Tofman 
PrioritynormalSeverityminorReproducibilityalways
StatusresolvedResolutionfixed 
PlatformOSOS Version
Product Version1.9.19 (2019 Q1) 
Fixed in Version1.9.20 Raijing DEV 
Summary0008660: API-XMLRPC - PHP Fatal error, when calling getTestCaseAttachments with unknown testcaseid
DescriptionThe TL 1.9.19 change on _xmlrpc.class.php_ method *getTestCaseAttachments* is not error safe

Calling *getTestCaseAttachments* with an unknown testcaseid returns
- with 1.9.18 the message *5000: The Test Case ID (testcaseid: 4711007) provided does not exist!*
- with 1.9.19 a *500 Internal Server Error*
Additional Informationhttpd error.log
[Thu May 09 21:41:38.073512 2019] [:error] [pid 662] [client 2001:16b8:22cc:8500:f5b3:9e23:ef67:9643:53688] PHP Fatal error:\
  Cannot use object of type IXR_Error as array in /usr/local/www/testlink-1.9.19/lib/api/xmlrpc/v1/xmlrpc.class.php on line \
3627

Events - Warning
09/05/2019 21:41:42 E_NOTICE Use of undefined constant NO_USER_BY_ID_LOGIN - assumed 'NO_USER_BY_ID_LOGIN' - in /usr/local/www/testlink-1.9.19/lib/api/xmlrpc/v1/xmlrpc.class.php - Line 6134
09/05/2019 21:41:35 E_WARNING current() expects parameter 1 to be array, null given - in /usr/local/www/testlink-1.9.19/lib/api/xmlrpc/v1/xmlrpc.class.php - Line 284
TagsNo tags attached.
Database (MySQL,Postgres,etc)postgresql 9.6
Browser
PHP Version
TestCaseID
QA Team - Task Workflow StatusREADY FOR TESTING
Attached Files

- Relationships
related to 0008658assignedfman API-XMLRPC - getTestCaseAttachments returns no attachment, uploaded with uploadTestCaseAttachment 
child of 0008549assignedfman Availables hot-fixes for 1.9.19 & How To get full fixed package from GitHub 

-  Notes
(0028830)
fman (administrator)
2019-05-16 15:04

please try
https://github.com/TestLinkOpenSourceTRMS/testlink-code/commit/c9d82ef654b88bb43a25847303633a4e18386679 [^]
(0028831)
lczub (reporter)
2019-05-16 19:34

retest 0008660 passed only partly
- Calling *getTestCaseAttachments* with an unknown testcaseid raise no internal server error any more

BUT
- Calling *getTestCase* with unknown 'testcaseexternalid' or 'testcaseexternalid' raise now an internal server error

retest 0008658 failed, workflow uploadTestCaseAttachment + getTestCaseAttachment without optional parameter *version* still does not work
(0028838)
fman (administrator)
2019-05-19 17:53

getTestCase() fix
https://github.com/TestLinkOpenSourceTRMS/testlink-code/commit/c3322c0fcb885c8b8c14c12e123ea3ae7c520e02 [^]
(0028839)
fman (administrator)
2019-05-19 18:38

https://github.com/TestLinkOpenSourceTRMS/testlink-code/commit/d32e464590787c77c9ca4b528bcd9a3eb4049ad4 [^]

uploadTestCaseAttachment()
(0028850)
lczub (reporter)
2019-05-22 20:26

retest results with commit state 7c3b3fabb fix: missing joins

1.) calling getTestCase and getTestCaseAttachments with unknown testcaseid - passed - no server error occur anymore

2.) workflow uploadTestCaseAttachment + getTestCaseAttachment still not work for me. Both variants (calling with or without parameter version) returns no attachement.
I have to investigate, if my calls are wrong or the server code. (not before the weekend ). I can see many WARNINGS like
- E_NOTICE Undefined offset / Undefined variable: / Undefined index: - in ... api/xmlrpc/v1/xmlrpc.class.php

My suggestion would be, to mark the issue 8660 as fixed and the issue 8658 as still open.
(0028869)
lczub (reporter)
2019-05-26 18:41

Repeating the uploadTestCaseAttachment test with latest github commit dd12882f8 still ends in the error state, that it is not possible to store an attachment, even when both parameter 'testcaseid' and 'version' are submitted.

Should I still use this ticket 8660 or report it in 8658?

- Issue History
Date Modified Username Field Change
2019-05-09 20:14 lczub New Issue
2019-05-16 14:32 fman Relationship added related to 0008658
2019-05-16 15:04 fman Note Added: 0028830
2019-05-16 19:34 lczub Note Added: 0028831
2019-05-19 17:53 fman Note Added: 0028838
2019-05-19 18:38 fman Note Added: 0028839
2019-05-19 18:38 fman Assigned To => fman
2019-05-19 18:38 fman Status new => feedback
2019-05-22 20:26 lczub Note Added: 0028850
2019-05-22 20:26 lczub Status feedback => assigned
2019-05-26 18:41 lczub Note Added: 0028869
2019-05-28 18:25 fman QA Team - Task Workflow Status => READY FOR TESTING
2019-05-28 18:25 fman Status assigned => resolved
2019-05-28 18:25 fman Fixed in Version => 1.9.20 Raijing DEV
2019-05-28 18:25 fman Resolution open => fixed
2019-05-28 18:26 fman Relationship added child of 0008549



Copyright © 2000 - 2019 MantisBT Team
Powered by Mantis Bugtracker