Details

    • Type: Bug
    • Status: Ungroomed
    • Priority: Unset
    • Resolution: Unresolved
    • Affects versions: None
    • Fix versions: None
    • Labels:
      None
    • Sprint:

      Description

      The doctests for bok-choy now routinely fail on attempts to load a GitHub page, probably because we're hitting it often enough to be throttled (especially because of multiple parallel Travis workers). Fix these tests/examples to use something that works more reliably. Example of the problem:

      doc run-test: commands[5] | python docs/code/round_3/test_search.py
      ./home/travis/build/edx/bok-choy/.tox/doc/lib/python3.6/site-packages/urllib3/poolmanager.py:97: ResourceWarning: unclosed <socket.socket fd=5, family=AddressFamily.AF_INET, type=SocketKind.SOCK_STREAM, proto=6, laddr=('127.0.0.1', 50152), raddr=('127.0.0.1', 50417)>
        for key in list(context.keys()):
      E
      ======================================================================
      ERROR: test_search (__main__.TestGitHub)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "docs/code/round_3/test_search.py", line 28, in test_search
          self.github_search_page.visit().search_for_terms('user:edx repo:edx-platform')
        File "/home/travis/build/edx/bok-choy/.tox/doc/lib/python3.6/site-packages/bok_choy-1.0.0-py3.6.egg/bok_choy/page_object.py", line 123, in wrapper
          return method(self, *args, **kwargs)
        File "/home/travis/build/edx/bok-choy/docs/code/round_3/pages.py", line 57, in search_for_terms
          self.search()
        File "/home/travis/build/edx/bok-choy/.tox/doc/lib/python3.6/site-packages/bok_choy-1.0.0-py3.6.egg/bok_choy/page_object.py", line 123, in wrapper
          return method(self, *args, **kwargs)
        File "/home/travis/build/edx/bok-choy/docs/code/round_3/pages.py", line 49, in search
          GitHubSearchResultsPage(self.browser).wait_for_page()
        File "/home/travis/build/edx/bok-choy/.tox/doc/lib/python3.6/site-packages/bok_choy-1.0.0-py3.6.egg/bok_choy/page_object.py", line 471, in wait_for_page
          timeout=timeout
        File "/home/travis/build/edx/bok-choy/.tox/doc/lib/python3.6/site-packages/bok_choy-1.0.0-py3.6.egg/bok_choy/promise.py", line 106, in fulfill
          raise BrokenPromise(self)
      bok_choy.promise.BrokenPromise: Promise not satisfied: loaded page <pages.GitHubSearchResultsPage object at 0x7f0808f6ae10>
      

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              jbowman Jeremy Bowman
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: