Title: [264399] trunk/Tools
Revision
264399
Author
aakash_j...@apple.com
Date
2020-07-15 09:24:23 -0700 (Wed, 15 Jul 2020)

Log Message

[ews-app] Add timeout to network requests
https://bugs.webkit.org/show_bug.cgi?id=214355

Reviewed by Jonathan Bedard.

* BuildSlaveSupport/ews-app/ews/common/util.py:
(fetch_data_from_url): Add tiemout as recommended in https://requests.readthedocs.io/en/master/user/quickstart/#timeouts

Modified Paths

Diff

Modified: trunk/Tools/BuildSlaveSupport/ews-app/ews/common/util.py (264398 => 264399)


--- trunk/Tools/BuildSlaveSupport/ews-app/ews/common/util.py	2020-07-15 14:51:35 UTC (rev 264398)
+++ trunk/Tools/BuildSlaveSupport/ews-app/ews/common/util.py	2020-07-15 16:24:23 UTC (rev 264399)
@@ -1,4 +1,4 @@
-# Copyright (C) 2018-2019 Apple Inc. All rights reserved.
+# Copyright (C) 2018-2020 Apple Inc. All rights reserved.
 #
 # Redistribution and use in source and binary forms, with or without
 # modification, are permitted provided that the following conditions
@@ -30,7 +30,7 @@
     _log.debug('Fetching: {}'.format(url))
     response = None
     try:
-        response = requests.get(url)
+        response = requests.get(url, timeout=10)
     except Exception as e:
         if response:
             _log.error('Failed to access {url} with status code {status_code}.'.format(url="" status_code=response.status_code))

Modified: trunk/Tools/ChangeLog (264398 => 264399)


--- trunk/Tools/ChangeLog	2020-07-15 14:51:35 UTC (rev 264398)
+++ trunk/Tools/ChangeLog	2020-07-15 16:24:23 UTC (rev 264399)
@@ -1,5 +1,15 @@
 2020-07-15  Aakash Jain  <aakash_j...@apple.com>
 
+        [ews-app] Add timeout to network requests
+        https://bugs.webkit.org/show_bug.cgi?id=214355
+
+        Reviewed by Jonathan Bedard.
+
+        * BuildSlaveSupport/ews-app/ews/common/util.py:
+        (fetch_data_from_url): Add tiemout as recommended in https://requests.readthedocs.io/en/master/user/quickstart/#timeouts
+
+2020-07-15  Aakash Jain  <aakash_j...@apple.com>
+
         Make ews django app robust against network issues
         https://bugs.webkit.org/show_bug.cgi?id=214351
 
_______________________________________________
webkit-changes mailing list
webkit-changes@lists.webkit.org
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to