Open Bug 500377 Opened 16 years ago Updated 16 years ago

testopia.py fails to execute any action if the COOKIE_PATH is set to something else than /

Categories

(Testopia :: API, defect)

x86
Linux
defect
Not set
normal

Tracking

(Not tracked)

UNCONFIRMED

People

(Reporter: miloszw, Assigned: gregaryh)

Details

Attachments

(1 file)

User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9.0.6) Gecko/2009011913 Firefox/3.0.6 Build Identifier: Testopia 2.2 (Bugzilla 3.2) When the 'cookiepath' in <bugzilla_root>/data/params is set to some other value than '/', it is not possible to execute any action using testopia.py. The reason for that is default policy in cookielib, which drops all cookies with some path. The fix is pretty simple, but I'm not sure if it does not bring some security risks. Reproducible: Always Steps to Reproduce: 1. create example client using python driver - testopia.py: from testopia import Testopia URL = 'http://bugzilla.site.with.testopia/tr_xmlrpc.cgi' client = Testopia(username, password, URL) print client.testplan_get(1) #assume that test plan with id = 1 exists 2. execute the script Actual Results: testopia.TestopiaXmlrpcError: Error while executing cmd 'TestPlan.get(1)' --> <Fault 410: 'Login Required'> Expected Results: Test plan details are printed
Attached patch example fixSplinter Review
This is an example fix for the COOKIE_PATH problem. It works for me, but I guess someone should check if there is a better solution
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: