Closed Bug 1059949 Opened 10 years ago Closed 10 years ago

treeherder-ui should handle suggestion.bugs being null more gracefully


(Tree Management :: Treeherder, defect, P2)



(Not tracked)



(Reporter: emorley, Assigned: emorley)




(1 file, 1 obsolete file)

Attached patch Patch v1Splinter Review
I'm not sure what to do with this - either we use something hacky like this patch and remove it at a later date (given the service is now fixed), or we add more complete checking for missing properties. (But for the latter, we don't do this for everything else, and seems like we're at risk of bloating the UI code if we do it across the board).
Attachment #8480787 - Flags: feedback?(mdoglio)
Attachment #8480787 - Attachment is patch: true
Jonathan/Cameron, would either of you mind taking the review for this? (Didn't realise Mauro was away)
Comment on attachment 8480787 [details] [diff] [review]
Patch v1

Your solution is fine for now. I agree with your observations in comment 1 regarding property checking. I think the way to go there would be to have json schema validation that's specific to different job artifacts. This should be done with one set of javascript classes and implement the validation in a single place in the application. Out of the scope of this bug, would be a good task for a refactor in the future.

It will be more of an issue as we receive more types of data other than buildbot job artifacts, ones from jenkins/taskcluster will likely have different requirements for validation. So this could get messy fast without some better validation strategy.
Attachment #8480787 - Flags: review+
Comment on attachment 8480787 [details] [diff] [review]
Patch v1

Thank you - I'll file another bug for implementing more thorough json
schema validation in the ui.
Attachment #8480787 - Flags: checkin+
Closed: 10 years ago
Resolution: --- → FIXED
(In reply to Ed Morley [:edmorley] from comment #6)
> Thank you - I'll file another bug for implementing more thorough json
> schema validation in the ui.

Actually bug 1043338 is already filed for this.
Attachment #8480787 - Attachment description: WIP → Patch v1
Attachment #8480787 - Flags: feedback?(mdoglio)
Commit pushed to master at
Bug 1059949 - Handle bugs not having open_recent and all_other keys more gracefully; r=mdoglio

For a short time, treeherder-service was creating log artefacts that
were missing the open_recent and all_other keys on the bugs
property. This likely temporary workaround will let us view
the summaries for those jobs until enough time has passed
that we no longer care about them.
You need to log in before you can comment on or make changes to this bug.