Bug 223820 - [webkit-patch] Use commit.webkit.org instead of remote SVN to compute identifier
Summary: [webkit-patch] Use commit.webkit.org instead of remote SVN to compute identifier
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Jonathan Bedard
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-03-26 14:36 PDT by Jonathan Bedard
Modified: 2021-03-26 16:10 PDT (History)
5 users (show)

See Also:


Attachments
Patch (8.33 KB, patch)
2021-03-26 14:39 PDT, Jonathan Bedard
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Bedard 2021-03-26 14:36:22 PDT
Folks have objected to the time it takes to cache remote subversion data required to compute identifiers. Consulting commits.webkit.org will be faster.
Comment 1 Radar WebKit Bug Importer 2021-03-26 14:36:34 PDT
<rdar://problem/75902125>
Comment 2 Jonathan Bedard 2021-03-26 14:39:03 PDT
Created attachment 424406 [details]
Patch
Comment 3 dewei_zhu 2021-03-26 14:44:22 PDT
Comment on attachment 424406 [details]
Patch

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

> Tools/Scripts/webkitpy/tool/comments.py:42
> +    repr = 'r{}'.format(svn_revision)
> +    response = requests.get('https://commits.webkit.org/{}/json'.format(repr))
> +    if response.status_code == 200:
> +        repr = response.json().get('identifier', repr)
> +    return 'Committed r{} ({}): <{}>'.format(svn_revision, repr if '@' in repr else '?', urls.view_identifier_url(repr))

Should we consider using svn.webkit.org as a fallback just in case the former is down?
Comment 4 dewei_zhu 2021-03-26 14:44:51 PDT
r=me with comment.
Comment 5 Jonathan Bedard 2021-03-26 14:51:30 PDT
(In reply to dewei_zhu from comment #3)
> Comment on attachment 424406 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=424406&action=review
> 
> > Tools/Scripts/webkitpy/tool/comments.py:42
> > +    repr = 'r{}'.format(svn_revision)
> > +    response = requests.get('https://commits.webkit.org/{}/json'.format(repr))
> > +    if response.status_code == 200:
> > +        repr = response.json().get('identifier', repr)
> > +    return 'Committed r{} ({}): <{}>'.format(svn_revision, repr if '@' in repr else '?', urls.view_identifier_url(repr))
> 
> Should we consider using svn.webkit.org as a fallback just in case the
> former is down?

It's possible to use svn.webkit.org as a fallback, but the failure condition is pretty mild: you end up with this:
Committed r1234 (?) <https://commits.webkit.org/r1234> , I feel like defending the failure isn't worth maintaining the defense
Comment 6 EWS 2021-03-26 16:10:18 PDT
Committed r275119: <https://commits.webkit.org/r275119>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 424406 [details].