@@ -39,7 +39,7 @@ The priority chain consists of these steps:
3939 - RALLY_PROJECT
4040 * if present, use information from a rally-<version>.cfg file in the current directory,
4141 where <version> matches the Rally WSAPI version defined in the pyral.config module.
42- Currently, that version is defined as 1.29 .
42+ Currently, that version is defined as 1.37 .
4343 * if present, use the contents of a file named in the RALLY_CONFIG environment variable.
4444 * if present, use the contents of a config named on the command line via the --config-<filename>
4545 option
@@ -136,17 +136,17 @@ Rally
136136 either in this specific order or as keyword arguments.
137137
138138 You can optionally specify the following as keyword arguments.
139- * version
140139 * workspace
141140 * project
142- * version (specify the Rally WSAPI version, default is 1.29)
141+ * version (specify the Rally WSAPI version, default is 1.37)
142+ * verify_ssl_cert (True or False, default is True)
143143 * warn (True or False, default is True)
144144 Controls whether a warning is issued if no project is specified
145145 and the default project for the user is not in the workspace specified.
146146 Under those conditions, the project is changed to the first project
147147 (alphabetic ordering) in the list of projects for the specified workspace.
148148
149- .. py:class:: Rally (server, user, password, version=1.29 , workspace=None, project=None, warn=True)
149+ .. py:class:: Rally (server, user, password, version=1.34 , workspace=None, project=None, warn=True)
150150
151151Examples::
152152
@@ -156,7 +156,7 @@ Examples::
156156
157157 rally = Rally(server, user, password, workspace='Division #1 Products', project='ABC')
158158
159- rally = Rally(server, user, password, workspace='Brontoville', warn=False)
159+ rally = Rally(server, user, password, workspace='Brontoville', verify_ssl_cert=False, warn=False)
160160
161161
162162
@@ -305,10 +305,15 @@ pyral.Rally instance convenience methods
305305 that project in subsequent interractions with Rally.
306306
307307
308- .. method:: getProject(projectName )
308+ .. method:: getProject(name=None )
309309
310- Returns an instance of a Project entity with information about the project
311- in the currently active context.
310+ Returns a minimally hydrated Project entity instance with the Name and ref
311+ of the project in the currently active context if the name keyword arg
312+ is not supplied or the Name and ref of the project identified by the value of
313+ the name parameter as long as the name identifies a valid project in the currently
314+ selected workspace.
315+ Returns None if a name parameter is supplied that does not identify a valid project
316+ in the currently selected workspace.
312317
313318
314319.. method:: getProjects(workspace=None)
@@ -337,7 +342,6 @@ pyral.Rally instance convenience methods
337342 Returns None if there is no match in the Rally subscription/workspace for
338343 the keyword argument used to identify the user target.
339344
340-
341345.. method:: getAllUsers(workspace=None)
342346
343347 This method offers a convenient one-stop means of obtaining usable information
@@ -347,6 +351,28 @@ pyral.Rally instance convenience methods
347351 Return a list of User instances (fully hydrated for scalar attributes)
348352 whose ref and collection attributes will be lazy eval'ed upon access.
349353
354+ .. method:: typedef(entityName)
355+
356+ This method returns a TypeDefinition instance for the given entityName.
357+ The is handy for occasions where you need identify a specific entity
358+ for something like 'Feature' or 'Theme' when creating or updating a
359+ PortfolioItem subclass. Intended usage is to use the return *.ref* attribute.
360+ For example, within an info dict, "PortfolioItemType" : rally.typedef('Feature').ref .
361+
362+ .. method:: getState(entityName, stateName)
363+
364+ As of Rally WSAPI 1.37 (Sep 2012), the State attribute is no longer a String value for
365+ many entities, it is itself an entity (aka Rally Type). To be able to create (or update)
366+ an Artifact's State attribute, you must provide a reference (_ref or ref) in the information
367+ dictionary used to populate the Artifact's attributes. This method provides an
368+ easy means of obtaining the appropriate entity for the particular entity and state Name
369+ you want. Typically the usage would be along the lines of this example:
370+ info = { ...., "State" : rally.getState('Feature', 'Discovering').ref, ... })
371+
372+ .. method:: getStates(entityName)
373+
374+ Given an entityName, returns a list of State instances populated with information
375+ about each state value permitted for the entityName.
350376
351377.. method:: getAllowedValues(entityName, attributeName [,workspace=None])
352378
@@ -359,6 +385,7 @@ pyral.Rally instance convenience methods
359385 it exists and then attempt to add an Attachment with the name and
360386 contents of filename into Rally and associate that Attachment with the
361387 Artifact.
388+ Returns the Attachment item.
362389
363390.. method:: addAttachments(artifact, attachments)
364391
@@ -480,3 +507,50 @@ Item Attributes
480507 print task.oid, task.Name, task.ActualHours
481508
482509
510+ .. method:: details()
511+
512+ This convenience method is available on all *WorkspaceDomain*
513+ subclass instances and provides an organized and easy to read multiline string
514+ with the content of the instance.
515+
516+ Example::
517+
518+ response = rally.get('UserStory', fetch=True, query='FormattedID = S321')
519+ story1 = response.next()
520+ print story1.details()
521+
522+ HierarchicalRequirement
523+ oid : 12345678
524+ ref : hierarchicalrequirement/12345678
525+ ObjectID : 12345678
526+ _ref : https://rallydev.rallydev.com/slm/webservice/1.30/hierarchicalrequirement/12345678.js
527+ _CreatedAt : today at 3:14 am
528+ _hydrated : True
529+ Name : Filbert nuts should be added to all energy bars
530+ Subscription : Subscription.ref (OID 400060 Name: Company 1)
531+ Workspace : Workspace.ref (OID 722746 Name: Prime Cuts Workspace)
532+ FormattedID : S321
533+
534+ AcceptedDate : None
535+ AccountingProjec : None
536+ AccountingTask : None
537+ AffectedCustomer :
538+ Attachments : []
539+ Blocked : False
540+ Blocker : None
541+ Capitalizable : None
542+ Changesets : []
543+ Children : []
544+ CreationDate : 2012-07-12T09:14:35.852Z
545+ DefectStatus : NONE
546+ Defects : []
547+ Description : As a health conscious PO, I want better nutritional content in all bars
548+ Discussion : []
549+ IdeaURL : <pyral.entity.CustomField object at 0x101931290>
550+ IdeaVotes : None
551+ InProgressDate : 2012-07-12T09:14:36.098Z
552+ Iteration : Iteration.ref (OID 1242381 Name Iteration 5 (Summer))
553+ KanbanState : Accepted
554+ LastUpdateDate : 2012-07-12T09:14:36.237Z
555+ ...
556+
0 commit comments