2

When I use the PyRal get() function no results are returned, but if I use specific built-in get functions (e.g., getProjects(), getWorkspaces()) all data is returned correctly. Am I using the general get() incorrectly or do I have a configuration issue?

For the setup:

import sys
from pyral import Rally, rallyWorkset
server, user, password, apikey, workspace, project = <appropriate values>
rally = Rally(server, user, password, apikey=apikey, workspace=workspace, project=project)

These calls respond correctly (i.e., expected data returned):

workspacesAll = rally.getWorkspaces()
projectsAll = rally.getProjects(workspace=workspace)

No data returned for this call, no errors. The User Story exists in Rally.

query_criteria = 'FormattedID = "US220220"'
response = rally.get('HierarchicalRequirement', fetch=True, query=query_criteria)

Have also tried using "UserStory" instead of "HierarchicalRequirement" and other query criteria all without success.

tuomastik
  • 4,559
  • 5
  • 36
  • 48

1 Answers1

1

It will work if you go thru all Projects (not parent):

query_criteria = 'FormattedID = "US220220"'
response_req = rally.get('HierarchicalRequirement', fetch=True, projectScopeDown=True, query=query_criteria)
response = response_req.next()

print response.details()
user2738882
  • 1,161
  • 1
  • 20
  • 38