versionone/VersionOne.SDK.Python — pull request #11 by kbielefe (2014-03-24 16:43:29+00:00)
Title: Fix updating of single relation

This is to fix a problem I had while trying to update the status of a task. It was generating XML for the multi-relation when it should have been generating it for a single-relation. This change makes single relations just a pointer to a `BaseAsset`, instead of a pointer to a list containing a single `BaseAsset`. That allows discrimination between single and multi relations. Also, setting the pointer to `None` will generate the XML code to remove the relation.

This pull request also logs the posted xml data if an error occurred, which I found valuable during debugging.

Note, I also found a bug in the multi-relation part of this function, where it doesn't detect the removal of a relation. This prevents unassigning a member from a task, for example. I am considering possible solutions, and will submit that fix in a separate pull request.