Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
request: API XML result is rather inconsistent and poorly structured #3898
Having written extensive processing of requests for generating detailed metrics and re-creating project level staging state based on multiple requests I have run into quite some issues with the structure of the data and a few clear bugs.
Based on the structure I am going to assume this organically grew into this structure as it makes little sense to design it like this. The disconnect between
One would expect when passing
When a review is first added it will look something like:
<review state="new" when="2017-09-22T19:25:18" who="jberry" by_user="jberry_factory"> <comment>staging review</comment> </review>
<review state="accepted" when="2017-09-22T19:23:56" who="jberry_factory" by_user="jberry_factory"> <comment>psh</comment> <history who="jberry_factory" when="2017-09-22T19:24:37"> <description>Review got accepted</description> <comment>psh</comment> </history> </review>
Not only is
If one looks at the
<history who="jberry" when="2017-09-22T19:23:56"> <description>Request got a new review request</description> <comment>staging review</comment> </history>
Unfortunately, short of guessing the
Multiple state changes where a request is reviewed multiple times is even less trivial to walk since any comments are no longer unique enough to parse. This really does not need to be this way.
One can only imagine the level of absurd workarounds that I have implemented to extract something reasonable from this data. This should really be fixed.