Bug 194264 - [ews-app] Add method to save BuilderMapping to database
Summary: [ews-app] Add method to save BuilderMapping to database
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: Other
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Aakash Jain
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2019-02-04 18:15 PST by Aakash Jain
Modified: 2019-02-05 09:25 PST (History)
7 users (show)

See Also:


Attachments
Proposed patch (3.50 KB, patch)
2019-02-04 18:19 PST, Aakash Jain
lforschler: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Aakash Jain 2019-02-04 18:15:02 PST
We should add method to save Builder Mapping to database for ews-app.
Comment 1 Aakash Jain 2019-02-04 18:19:29 PST
Created attachment 361145 [details]
Proposed patch
Comment 2 Build Bot 2019-02-04 18:21:09 PST Comment hidden (obsolete)
Comment 3 Lucas Forschler 2019-02-05 09:07:58 PST
Comment on attachment 361145 [details]
Proposed patch

View in context: https://bugs.webkit.org/attachment.cgi?id=361145&action=review

> Tools/BuildSlaveSupport/ews-app/ews/models/buildermapping.py:59
> +            _log.error('builder_id {} does not match with builer_id {}. Ignoring new data.'.format(mapping.builder_id, builder_id))

nit: typo: builer
Comment 4 Jonathan Bedard 2019-02-05 09:15:55 PST
Comment on attachment 361145 [details]
Proposed patch

View in context: https://bugs.webkit.org/attachment.cgi?id=361145&action=review

> Tools/BuildSlaveSupport/ews-app/ews/models/buildermapping.py:80
> +    def is_valid_mapping(cls, builder_id, builder_name, display_name):

Why are we accepting builder_name and display_name if we don't do anything with them?
Comment 5 Aakash Jain 2019-02-05 09:23:10 PST
Committed r240977: <https://trac.webkit.org/changeset/240977>
Comment 6 Radar WebKit Bug Importer 2019-02-05 09:24:35 PST
<rdar://problem/47820191>
Comment 7 Aakash Jain 2019-02-05 09:25:55 PST
> Why are we accepting builder_name and display_name if we don't do anything with them?
It's not required, but I added it for future, we might want to add more validation later on (e.g.: ensuring that display_name is string).