Page MenuHomePhabricator

All TestSupersetWithAuth.test_login_and_oauth_permisson of superset_tests fails with ConnectionError
Closed, ResolvedPublic

Description

======================================================================
ERROR: test_login_and_oauth_permisson (tests.superset_tests.TestSupersetWithAuth)
Superset login and queries.
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/home/runner/work/pywikibot/pywikibot/tests/superset_tests.py", line 61, in test_login_and_oauth_permisson
    superset.login()
  File "/home/runner/work/pywikibot/pywikibot/pywikibot/data/superset.py", line 87, in login
    self.last_response = http.fetch(url)
  File "/home/runner/work/pywikibot/pywikibot/pywikibot/comms/http.py", line 457, in fetch
    callback(response)
  File "/home/runner/work/pywikibot/pywikibot/pywikibot/comms/http.py", line 327, in error_handling_callback
    raise ConnectionError(response)
ConnectionError: HTTPSConnectionPool(host='superset.wmcloud.org', port=443): Max retries exceeded with url: /login/mediawiki?next= (Caused by NameResolutionError("<urllib3.connection.HTTPSConnection object at 0x7f86c7eca7c0>: Failed to resolve 'superset.wmcloud.org' ([Errno -2] Name or service not known)"))
----------------------------------------------------------------------

Seems https://superset.wmcloud.org/ is not reachable:

D:\pwb\GIT\core>tracert superset.wmcloud.org
Der Zielname superset.wmcloud.org konnte nicht aufgelöst werden.

whereas wmcloud.org is avaqilable:

D:\pwb\GIT\core>tracert wmcloud.org

Routenverfolgung zu wmcloud.org [185.15.56.49]
über maximal 30 Hops:

  1     3 ms     1 ms     1 ms  <....>
  2    18 ms    22 ms    18 ms  <....>
  3    22 ms    18 ms    18 ms  <....>
  4    21 ms    23 ms    19 ms  <....>
  5    21 ms    19 ms    20 ms  <....>
  6    44 ms    21 ms    19 ms  <....>
  7     *        *        *     Zeitüberschreitung der Anforderung.
  8   236 ms   121 ms   183 ms  WIKIMEDIA-F.bear2.Washington111.Level3.net [4.16.71.246]
  9   205 ms   198 ms   209 ms  xe-0-0-0-1102.cloudsw1-c8-eqiad.wikimedia.org [208.80.154.211]
 10   152 ms   202 ms   204 ms  cloudgw1002.eqiad1.wikimediacloud.org [185.15.56.246]
 11   178 ms   112 ms   197 ms  accounts-dev.wmcloud.org [185.15.56.49]
 12   220 ms   198 ms   203 ms  accounts-dev.wmcloud.org [185.15.56.49]

Ablaufverfolgung beendet.

Event Timeline

Xqt triaged this task as High priority.Wed, Jun 19, 7:01 AM
Xqt moved this task from Backlog to Test failures on the Pywikibot-tests board.

I created a ticket T367945 for superset being down. Should we modify the test or wait if it will come back up?

Xqt updated the task description. (Show Details)
Xqt moved this task from Backlog to Reported Upstream on the Upstream board.

I created a ticket T367945 for superset being down. Should we modify the test or wait if it will come back up?

I think it depends on how quick is it solved upstream and whether this problem may accur later. The tests can be modified like this to skip the test:

def test_login_and_oauth_permisson(self):
    """Superset login and queries."""
    sql = 'SELECT page_id, page_title FROM page LIMIT 2;'
    site = self.get_site()
    self.assertTrue(site.logged_in())

    # Test login and initial site parameters
    superset = SupersetQuery(site=site)
    try:
        superset.login()
    except (ConnectionError, NoUsernameError):
        self.skipTest('Oauth permission is missing.')
    except ConnectionError as err:
        self.skipTest(err)
Xqt claimed this task.

Seems this is solved upstream

Change #1048283 had a related patch set uploaded (by Xqt; author: Xqt):

[pywikibot/core@master] [tests] skip superset_tests on ConnectionError

https://gerrit.wikimedia.org/r/1048283

Change #1048283 merged by jenkins-bot:

[pywikibot/core@master] [tests] skip superset_tests on ConnectionError

https://gerrit.wikimedia.org/r/1048283