Started by timer Running as SYSTEM Building remotely on Ubuntu_18.04_bioeng49 (buildslave Testing) in workspace /home/cmiss/Jenkins/workspace/SPARC-API-DEV [WS-CLEANUP] Deleting project workspace... [WS-CLEANUP] Deferred wipeout is used... [WS-CLEANUP] Done The recommended git tool is: NONE No credentials specified Cloning the remote Git repository Cloning repository https://github.com/nih-sparc/sparc-api.git > git init /home/cmiss/Jenkins/workspace/SPARC-API-DEV # timeout=10 Fetching upstream changes from https://github.com/nih-sparc/sparc-api.git > git --version # timeout=10 > git --version # 'git version 2.25.1' > git fetch --tags --force --progress -- https://github.com/nih-sparc/sparc-api.git +refs/heads/*:refs/remotes/origin/* # timeout=10 > git config remote.origin.url https://github.com/nih-sparc/sparc-api.git # timeout=10 > git config --add remote.origin.fetch +refs/heads/*:refs/remotes/origin/* # timeout=10 Avoid second fetch > git rev-parse refs/remotes/origin/master^{commit} # timeout=10 Checking out Revision e9378caae9e784a489b463fac8f5c7f03e8f46fb (refs/remotes/origin/master) > git config core.sparsecheckout # timeout=10 > git checkout -f e9378caae9e784a489b463fac8f5c7f03e8f46fb # timeout=10 Commit message: "Merge pull request #239 from nih-sparc/update-wrike-task-creation-to-ignore-captcha-check-during-testing" > git rev-list --no-walk 2048c5e04b09e49677f77192b1bdcfcee6a917dc # timeout=10 [SPARC-API-DEV] $ /bin/sh -xe /tmp/shiningpanda14976037886878592023.sh + pwd + export PYTHONPATH=/home/cmiss/Jenkins/workspace/SPARC-API-DEV + export SCICRUNCH_HOST=https://scicrunch.org/api/1/elastic/SPARC_PortalDatasets_dev + export PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python + pip install -r requirements.txt Requirement already satisfied: api==0.0.7 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 1)) (0.0.7) Requirement already satisfied: pennsieve==6.1.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 2)) (6.1.1) Requirement already satisfied: boto3==1.17.67 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 3)) (1.17.67) Requirement already satisfied: botocore==1.20.67 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 4)) (1.20.67) Requirement already satisfied: certifi==2019.11.28 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 5)) (2019.11.28) Requirement already satisfied: chardet==3.0.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 6)) (3.0.4) Collecting Click==7.1.2 (from -r requirements.txt (line 7)) Using cached click-7.1.2-py2.py3-none-any.whl.metadata (2.9 kB) Requirement already satisfied: docutils==0.15.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 8)) (0.15.2) Requirement already satisfied: Flask==1.1.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 9)) (1.1.1) Requirement already satisfied: flask-marshmallow==0.10.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 10)) (0.10.1) Requirement already satisfied: flask-cors==3.0.8 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 11)) (3.0.8) Requirement already satisfied: gunicorn==20.0.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 12)) (20.0.4) Requirement already satisfied: idna==2.8 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 13)) (2.8) Requirement already satisfied: itsdangerous==1.1.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 14)) (1.1.0) Requirement already satisfied: Jinja2==2.11.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 15)) (2.11.3) Requirement already satisfied: jmespath==0.9.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 16)) (0.9.4) Requirement already satisfied: MarkupSafe==1.1.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 17)) (1.1.1) Requirement already satisfied: marshmallow==3.2.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 18)) (3.2.2) Requirement already satisfied: nose==1.3.7 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 19)) (1.3.7) Requirement already satisfied: osparc==0.4.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 20)) (0.4.3) Requirement already satisfied: pillow in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 21)) (10.4.0) Requirement already satisfied: public==2019.4.13 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 22)) (2019.4.13) Requirement already satisfied: pytest in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 23)) (5.4.3) Requirement already satisfied: pymongo==3.8.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 24)) (3.8.0) Requirement already satisfied: python-dateutil==2.8.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 25)) (2.8.0) Requirement already satisfied: python-dotenv==0.10.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 26)) (0.10.3) Requirement already satisfied: query-string==2019.4.13 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 27)) (2019.4.13) Requirement already satisfied: requests==2.25.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 28)) (2.25.1) Requirement already satisfied: s3transfer==0.4.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 29)) (0.4.2) Requirement already satisfied: sendgrid==6.9.7 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 30)) (6.9.7) Requirement already satisfied: six==1.13.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 31)) (1.13.0) Requirement already satisfied: SQLAlchemy==1.3.20 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 32)) (1.3.20) Requirement already satisfied: urllib3==1.26.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 33)) (1.26.4) Requirement already satisfied: Werkzeug==0.16.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 34)) (0.16.0) Requirement already satisfied: psycopg2-binary==2.9.9 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 35)) (2.9.9) Requirement already satisfied: APScheduler==3.7.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 36)) (3.7.0) Requirement already satisfied: google-api-python-client==2.52.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 37)) (2.52.0) Requirement already satisfied: oauth2client==4.1.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 38)) (4.1.3) Requirement already satisfied: algoliasearch==2.6.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 39)) (2.6.2) Requirement already satisfied: contentful==1.13.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 40)) (1.13.1) Requirement already satisfied: contentful_management==2.11.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 41)) (2.11.0) Requirement already satisfied: Flask-Caching==2.3.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements.txt (line 42)) (2.3.0) Requirement already satisfied: configparser>=3.5 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (7.1.0) Requirement already satisfied: deprecated>=1.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (1.2.14) Requirement already satisfied: future>=0.15.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (1.0.0) Requirement already satisfied: futures in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (3.0.5) Requirement already satisfied: protobuf>=3.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (5.28.0) Requirement already satisfied: python-jose==3.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (3.2.0) Requirement already satisfied: pytz>=2016 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (2024.1) Requirement already satisfied: rsa==4.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (4.0) Requirement already satisfied: semver>=2.8.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (3.0.2) Requirement already satisfied: websocket-client>=0.57.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (1.8.0) Requirement already satisfied: docopt>=0.6 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (0.6.2) Requirement already satisfied: psutil>=5.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements.txt (line 2)) (6.0.0) Requirement already satisfied: setuptools>=3.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from gunicorn==20.0.4->-r requirements.txt (line 12)) (74.1.2) Requirement already satisfied: python-http-client>=3.2.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from sendgrid==6.9.7->-r requirements.txt (line 30)) (3.3.7) Requirement already satisfied: starkbank-ecdsa>=2.0.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from sendgrid==6.9.7->-r requirements.txt (line 30)) (2.2.0) Requirement already satisfied: tzlocal~=2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from APScheduler==3.7.0->-r requirements.txt (line 36)) (2.1) Requirement already satisfied: httplib2<1dev,>=0.15.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-python-client==2.52.0->-r requirements.txt (line 37)) (0.22.0) Requirement already satisfied: google-auth<3.0.0dev,>=1.19.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-python-client==2.52.0->-r requirements.txt (line 37)) (2.34.0) Requirement already satisfied: google-auth-httplib2>=0.1.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-python-client==2.52.0->-r requirements.txt (line 37)) (0.2.0) Requirement already satisfied: google-api-core!=2.0.*,!=2.1.*,!=2.2.*,!=2.3.0,<3.0.0dev,>=1.31.5 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-python-client==2.52.0->-r requirements.txt (line 37)) (2.19.2) Requirement already satisfied: uritemplate<5,>=3.0.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-python-client==2.52.0->-r requirements.txt (line 37)) (4.1.1) Requirement already satisfied: pyasn1>=0.1.7 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from oauth2client==4.1.3->-r requirements.txt (line 38)) (0.6.0) Requirement already satisfied: pyasn1-modules>=0.0.5 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from oauth2client==4.1.3->-r requirements.txt (line 38)) (0.4.0) Requirement already satisfied: cachelib<0.10.0,>=0.9.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from Flask-Caching==2.3.0->-r requirements.txt (line 42)) (0.9.0) Requirement already satisfied: ecdsa<0.15 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from python-jose==3.2.0->pennsieve==6.1.1->-r requirements.txt (line 2)) (0.14.1) Requirement already satisfied: py>=1.5.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (1.11.0) Requirement already satisfied: packaging in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (24.1) Requirement already satisfied: attrs>=17.4.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (24.2.0) Requirement already satisfied: more-itertools>=4.0.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (10.5.0) Requirement already satisfied: pluggy<1.0,>=0.12 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (0.13.1) Requirement already satisfied: wcwidth in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest->-r requirements.txt (line 23)) (0.2.13) Requirement already satisfied: wrapt<2,>=1.10 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from deprecated>=1.2.0->pennsieve==6.1.1->-r requirements.txt (line 2)) (1.16.0) Requirement already satisfied: googleapis-common-protos<2.0.dev0,>=1.56.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-core!=2.0.*,!=2.1.*,!=2.2.*,!=2.3.0,<3.0.0dev,>=1.31.5->google-api-python-client==2.52.0->-r requirements.txt (line 37)) (1.65.0) Requirement already satisfied: proto-plus<2.0.0dev,>=1.22.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-api-core!=2.0.*,!=2.1.*,!=2.2.*,!=2.3.0,<3.0.0dev,>=1.31.5->google-api-python-client==2.52.0->-r requirements.txt (line 37)) (1.24.0) Requirement already satisfied: cachetools<6.0,>=2.0.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from google-auth<3.0.0dev,>=1.19.0->google-api-python-client==2.52.0->-r requirements.txt (line 37)) (5.5.0) Requirement already satisfied: pyparsing!=3.0.0,!=3.0.1,!=3.0.2,!=3.0.3,<4,>=2.4.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from httplib2<1dev,>=0.15.0->google-api-python-client==2.52.0->-r requirements.txt (line 37)) (3.1.4) Using cached click-7.1.2-py2.py3-none-any.whl (82 kB) Installing collected packages: Click Attempting uninstall: Click Found existing installation: click 8.1.7 Uninstalling click-8.1.7: Successfully uninstalled click-8.1.7 ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts. black 24.8.0 requires click>=8.0.0, but you have click 7.1.2 which is incompatible. Successfully installed Click-7.1.2 + pip install -r requirements-dev.txt Requirement already satisfied: pytest==5.4.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 1)) (5.4.3) Requirement already satisfied: pennsieve==6.1.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 2)) (6.1.1) Requirement already satisfied: black in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 3)) (24.8.0) Requirement already satisfied: isort in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 4)) (5.13.2) Requirement already satisfied: nose in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 5)) (1.3.7) Requirement already satisfied: packaging in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from -r requirements-dev.txt (line 6)) (24.1) Requirement already satisfied: py>=1.5.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest==5.4.3->-r requirements-dev.txt (line 1)) (1.11.0) Requirement already satisfied: attrs>=17.4.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest==5.4.3->-r requirements-dev.txt (line 1)) (24.2.0) Requirement already satisfied: more-itertools>=4.0.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest==5.4.3->-r requirements-dev.txt (line 1)) (10.5.0) Requirement already satisfied: pluggy<1.0,>=0.12 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest==5.4.3->-r requirements-dev.txt (line 1)) (0.13.1) Requirement already satisfied: wcwidth in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pytest==5.4.3->-r requirements-dev.txt (line 1)) (0.2.13) Requirement already satisfied: boto3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.17.67) Requirement already satisfied: configparser>=3.5 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (7.1.0) Requirement already satisfied: deprecated>=1.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.2.14) Requirement already satisfied: future>=0.15.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.0.0) Requirement already satisfied: futures in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (3.0.5) Requirement already satisfied: protobuf>=3.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (5.28.0) Requirement already satisfied: python-jose==3.2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (3.2.0) Requirement already satisfied: pytz>=2016 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (2024.1) Requirement already satisfied: requests>=2.18 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (2.25.1) Requirement already satisfied: rsa==4.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (4.0) Requirement already satisfied: semver>=2.8.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (3.0.2) Requirement already satisfied: websocket-client>=0.57.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.8.0) Requirement already satisfied: docopt>=0.6 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (0.6.2) Requirement already satisfied: psutil>=5.4 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (6.0.0) Requirement already satisfied: python-dateutil>=2.8.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (2.8.0) Requirement already satisfied: six<2.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from python-jose==3.2.0->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.13.0) Requirement already satisfied: ecdsa<0.15 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from python-jose==3.2.0->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (0.14.1) Requirement already satisfied: pyasn1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from python-jose==3.2.0->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (0.6.0) Collecting click>=8.0.0 (from black->-r requirements-dev.txt (line 3)) Using cached click-8.1.7-py3-none-any.whl.metadata (3.0 kB) Requirement already satisfied: mypy-extensions>=0.4.3 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from black->-r requirements-dev.txt (line 3)) (1.0.0) Requirement already satisfied: pathspec>=0.9.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from black->-r requirements-dev.txt (line 3)) (0.12.1) Requirement already satisfied: platformdirs>=2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from black->-r requirements-dev.txt (line 3)) (4.3.2) Requirement already satisfied: tomli>=1.1.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from black->-r requirements-dev.txt (line 3)) (2.0.1) Requirement already satisfied: typing-extensions>=4.0.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from black->-r requirements-dev.txt (line 3)) (4.12.2) Requirement already satisfied: wrapt<2,>=1.10 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from deprecated>=1.2.0->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.16.0) Requirement already satisfied: chardet<5,>=3.0.2 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from requests>=2.18->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (3.0.4) Requirement already satisfied: idna<3,>=2.5 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from requests>=2.18->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (2.8) Requirement already satisfied: urllib3<1.27,>=1.21.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from requests>=2.18->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.26.4) Requirement already satisfied: certifi>=2017.4.17 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from requests>=2.18->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (2019.11.28) Requirement already satisfied: botocore<1.21.0,>=1.20.67 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from boto3->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (1.20.67) Requirement already satisfied: jmespath<1.0.0,>=0.7.1 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from boto3->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (0.9.4) Requirement already satisfied: s3transfer<0.5.0,>=0.4.0 in /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages (from boto3->pennsieve==6.1.1->-r requirements-dev.txt (line 2)) (0.4.2) Using cached click-8.1.7-py3-none-any.whl (97 kB) Installing collected packages: click Attempting uninstall: click Found existing installation: click 7.1.2 Uninstalling click-7.1.2: Successfully uninstalled click-7.1.2 Successfully installed click-8.1.7 + pytest ============================= test session starts ============================== platform linux -- Python 3.9.20, pytest-5.4.3, py-1.11.0, pluggy-0.13.1 rootdir: /home/cmiss/Jenkins/workspace/SPARC-API-DEV collected 109 items tests/test_api.py ..............FFFF. [ 17%] tests/test_biolucida.py ............. [ 29%] tests/test_dataset_info.py .s..ss..... [ 39%] tests/test_health.py . [ 40%] tests/test_monthly_stats.py ......... [ 48%] tests/test_osparc.py .............. [ 61%] tests/test_pmr.py ......... [ 69%] tests/test_scicrunch.py .................s......... [ 94%] tests/test_segmentation_info.py .. [ 96%] tests/test_thumbnails.py .FF [ 99%] tests/test_update_contentful_entries.py . [100%] =================================== FAILURES =================================== ____________________________ test_onto_term_lookup _____________________________ client = > def test_onto_term_lookup(client): r = client.get('/onto_term_lookup', query_string={'term': 'http://purl.obolibrary.org/obo/NCBITaxon_9606'}) > assert r.status_code == 200 E assert 500 == 200 E + where 500 = .status_code tests/test_api.py:194: AssertionError ----------------------------- Captured stderr call ----------------------------- --- Logging error --- Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 169, in _new_conn conn = connection.create_connection( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "/usr/lib/python3.9/socket.py", line 966, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn conn.connect() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 353, in connect conn = self._new_conn() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py", line 439, in send resp = conn.urlopen( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 755, in urlopen retries = retries.increment( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/app/main.py", line 1525, in find_by_onto_term response = requests.get(f'{Config.SCI_CRUNCH_INTERLEX_HOST}/_search', headers=headers, params=params, json=query) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py", line 76, in get return request('get', url, params=params, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py", line 61, in request return session.request(method=method, url=url, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py", line 542, in request resp = self.send(prep, **send_kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py", line 655, in send r = adapter.send(request, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.9/logging/__init__.py", line 1083, in emit msg = self.format(record) File "/usr/lib/python3.9/logging/__init__.py", line 927, in format return fmt.format(record) File "/usr/lib/python3.9/logging/__init__.py", line 663, in format record.message = record.getMessage() File "/usr/lib/python3.9/logging/__init__.py", line 367, in getMessage msg = msg % self.args TypeError: not all arguments converted during string formatting Call stack: File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/bin/pytest", line 8, in sys.exit(main()) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/config/__init__.py", line 124, in main ret = config.hook.pytest_cmdline_main( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 240, in pytest_cmdline_main return wrap_session(config, _main) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 191, in wrap_session session.exitstatus = doit(config, session) or 0 File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 247, in _main config.hook.pytest_runtestloop(session=session) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 272, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 85, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 100, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 186, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 216, in call_runtest_hook return CallInfo.from_call( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 244, in from_call result = func() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 217, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 135, in pytest_runtest_call item.runtest() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/python.py", line 1477, in runtest self.ihook.pytest_pyfunc_call(pyfuncitem=self) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/python.py", line 182, in pytest_pyfunc_call result = testfunction(**testargs) File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/tests/test_api.py", line 193, in test_onto_term_lookup r = client.get('/onto_term_lookup', query_string={'term': 'http://purl.obolibrary.org/obo/NCBITaxon_9606'}) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 1029, in get return self.open(*args, **kw) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/testing.py", line 222, in open return Client.open( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 993, in open response = self.run_wsgi_app(environ.copy(), buffered=buffered) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 884, in run_wsgi_app rv = run_wsgi_app(self.application, environ, buffered=buffered) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 1119, in run_wsgi_app app_rv = app(environ, start_response) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 2463, in __call__ return self.wsgi_app(environ, start_response) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 2446, in wsgi_app response = self.full_dispatch_request() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 1949, in full_dispatch_request rv = self.dispatch_request() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 1935, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/app/main.py", line 1538, in find_by_onto_term logging.error("An error occured while fetching from SciCrunch", ex) Message: 'An error occured while fetching from SciCrunch' Arguments: (ConnectionError(MaxRetryError("HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known'))")),) --- Logging error --- Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 169, in _new_conn conn = connection.create_connection( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/connection.py", line 73, in create_connection for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): File "/usr/lib/python3.9/socket.py", line 966, in getaddrinfo for res in _socket.getaddrinfo(host, port, family, type, proto, flags): socket.gaierror: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 699, in urlopen httplib_response = self._make_request( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 382, in _make_request self._validate_conn(conn) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 1010, in _validate_conn conn.connect() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 353, in connect conn = self._new_conn() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py", line 181, in _new_conn raise NewConnectionError( urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -2] Name or service not known During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py", line 439, in send resp = conn.urlopen( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py", line 755, in urlopen retries = retries.increment( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/retry.py", line 574, in increment raise MaxRetryError(_pool, url, error or ResponseError(cause)) urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/app/main.py", line 1525, in find_by_onto_term response = requests.get(f'{Config.SCI_CRUNCH_INTERLEX_HOST}/_search', headers=headers, params=params, json=query) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py", line 76, in get return request('get', url, params=params, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py", line 61, in request return session.request(method=method, url=url, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py", line 542, in request resp = self.send(prep, **send_kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py", line 655, in send r = adapter.send(request, **kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py", line 516, in send raise ConnectionError(e, request=request) requests.exceptions.ConnectionError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/lib/python3.9/logging/__init__.py", line 1083, in emit msg = self.format(record) File "/usr/lib/python3.9/logging/__init__.py", line 927, in format return fmt.format(record) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/logging.py", line 74, in format return super().format(record) File "/usr/lib/python3.9/logging/__init__.py", line 663, in format record.message = record.getMessage() File "/usr/lib/python3.9/logging/__init__.py", line 367, in getMessage msg = msg % self.args TypeError: not all arguments converted during string formatting Call stack: File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/bin/pytest", line 8, in sys.exit(main()) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/config/__init__.py", line 124, in main ret = config.hook.pytest_cmdline_main( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 240, in pytest_cmdline_main return wrap_session(config, _main) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 191, in wrap_session session.exitstatus = doit(config, session) or 0 File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 247, in _main config.hook.pytest_runtestloop(session=session) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/main.py", line 272, in pytest_runtestloop item.config.hook.pytest_runtest_protocol(item=item, nextitem=nextitem) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 85, in pytest_runtest_protocol runtestprotocol(item, nextitem=nextitem) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 100, in runtestprotocol reports.append(call_and_report(item, "call", log)) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 186, in call_and_report call = call_runtest_hook(item, when, **kwds) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 216, in call_runtest_hook return CallInfo.from_call( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 244, in from_call result = func() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 217, in lambda: ihook(item=item, **kwds), when=when, reraise=reraise File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/runner.py", line 135, in pytest_runtest_call item.runtest() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/python.py", line 1477, in runtest self.ihook.pytest_pyfunc_call(pyfuncitem=self) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/hooks.py", line 286, in __call__ return self._hookexec(self, self.get_hookimpls(), kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 93, in _hookexec return self._inner_hookexec(hook, methods, kwargs) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/manager.py", line 84, in self._inner_hookexec = lambda hook, methods, kwargs: hook.multicall( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pluggy/callers.py", line 187, in _multicall res = hook_impl.function(*args) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/python.py", line 182, in pytest_pyfunc_call result = testfunction(**testargs) File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/tests/test_api.py", line 193, in test_onto_term_lookup r = client.get('/onto_term_lookup', query_string={'term': 'http://purl.obolibrary.org/obo/NCBITaxon_9606'}) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 1029, in get return self.open(*args, **kw) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/testing.py", line 222, in open return Client.open( File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 993, in open response = self.run_wsgi_app(environ.copy(), buffered=buffered) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 884, in run_wsgi_app rv = run_wsgi_app(self.application, environ, buffered=buffered) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py", line 1119, in run_wsgi_app app_rv = app(environ, start_response) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 2463, in __call__ return self.wsgi_app(environ, start_response) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 2446, in wsgi_app response = self.full_dispatch_request() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 1949, in full_dispatch_request rv = self.dispatch_request() File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py", line 1935, in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) File "/home/cmiss/Jenkins/workspace/SPARC-API-DEV/app/main.py", line 1538, in find_by_onto_term logging.error("An error occured while fetching from SciCrunch", ex) File "/usr/lib/python3.9/logging/__init__.py", line 2064, in error root.error(msg, *args, **kwargs) File "/usr/lib/python3.9/logging/__init__.py", line 1475, in error self._log(ERROR, msg, args, **kwargs) File "/usr/lib/python3.9/logging/__init__.py", line 1589, in _log self.handle(record) File "/usr/lib/python3.9/logging/__init__.py", line 1599, in handle self.callHandlers(record) File "/usr/lib/python3.9/logging/__init__.py", line 1661, in callHandlers hdlr.handle(record) File "/usr/lib/python3.9/logging/__init__.py", line 952, in handle self.emit(record) File "/home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/_pytest/logging.py", line 310, in emit logging.StreamHandler.emit(self, record) Message: 'An error occured while fetching from SciCrunch' Arguments: (ConnectionError(MaxRetryError("HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/Interlex_pr/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known'))")),) _____________________ test_non_existing_simulation_ui_file _____________________ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: > conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:169: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ address = ('scicrunch.org', 443), timeout = None, source_address = None socket_options = [(6, 1, 1)] def create_connection( address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, source_address=None, socket_options=None, ): """Connect to *address* and return the socket object. Convenience function. Connect to *address* (a 2-tuple ``(host, port)``) and return the socket object. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setting returned by :func:`socket.getdefaulttimeout` is used. If *source_address* is set it must be a tuple of (host, port) for the socket to bind as a source address before making the connection. An host of '' or port 0 tells the OS to use the default. """ host, port = address if host.startswith("["): host = host.strip("[]") err = None # Using the value from allowed_gai_family() in the context of getaddrinfo lets # us select whether to work with IPv4 DNS records, IPv6 records, or both. # The original create_connection function always returns all records. family = allowed_gai_family() try: host.encode("idna") except UnicodeError: return six.raise_from( LocationParseError(u"'%s', label empty or too long" % host), None ) > for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/connection.py:73: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ host = 'scicrunch.org', port = 443, family = type = , proto = 0, flags = 0 def getaddrinfo(host, port, family=0, type=0, proto=0, flags=0): """Resolve host and port into list of address info entries. Translate the host/port argument into a sequence of 5-tuples that contain all the necessary arguments for creating a socket connected to that service. host is a domain name, a string representation of an IPv4/v6 address or None. port is a string service name such as 'http', a numeric port number or None. By passing None as the value of host and port, you can pass NULL to the underlying C API. The family, type and proto arguments can be optionally specified in order to narrow the list of addresses returned. Passing zero as a value for each of these arguments selects the full range of results. """ # We override this function since we want to translate the numeric family # and socket type values to enum constants. addrlist = [] > for res in _socket.getaddrinfo(host, port, family, type, proto, flags): E socket.gaierror: [Errno -2] Name or service not known /usr/lib/python3.9/socket.py:966: gaierror During handling of the above exception, another exception occurred: self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "137"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. > httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:699: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' timeout = Timeout(connect=None, read=None, total=None), chunked = False httplib_request_kw = {'body': b'{"query": {"term": {"pennsieve.identifier.aggregate": "137"}}}', 'headers': {'User-Agent': 'python-requests...ip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'}} timeout_obj = Timeout(connect=None, read=None, total=None) def _make_request( self, conn, method, url, timeout=_Default, chunked=False, **httplib_request_kw ): """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param timeout: Socket timeout in seconds for the request. This can be a float or integer, which will set the same timeout value for the socket connect and the socket read, or an instance of :class:`urllib3.util.Timeout`, which gives you more fine-grained control over your timeouts. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = timeout_obj.connect_timeout # Trigger any extra validation we need to do. try: > self._validate_conn(conn) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:382: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = def _validate_conn(self, conn): """ Called right before a request is made, after the socket is created. """ super(HTTPSConnectionPool, self)._validate_conn(conn) # Force connect early to allow us to validate the connection. if not getattr(conn, "sock", None): # AppEngine might not have `.sock` > conn.connect() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:1010: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def connect(self): # Add certificate verification > conn = self._new_conn() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:353: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) except SocketTimeout: raise ConnectTimeoutError( self, "Connection to %s timed out. (connect timeout=%s)" % (self.host, self.timeout), ) except SocketError as e: > raise NewConnectionError( self, "Failed to establish a new connection: %s" % e ) E urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -2] Name or service not known ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:181: NewConnectionError During handling of the above exception, another exception occurred: self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:439: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "137"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) # If we're going to release the connection in ``finally:``, then # the response doesn't need to know about the connection. Otherwise # it will also try to release it and we'll have a double-release # mess. response_conn = conn if not release_conn else None # Pass method to Response for length checking response_kw["request_method"] = method # Import httplib's response into our own wrapper object response = self.ResponseCls.from_httplib( httplib_response, pool=self, connection=response_conn, retries=retries, **response_kw ) # Everything went great! clean_exit = True except EmptyPoolError: # Didn't get a connection from the pool, no need to clean up clean_exit = True release_this_conn = False raise except ( TimeoutError, HTTPException, SocketError, ProtocolError, BaseSSLError, SSLError, CertificateError, ) as e: # Discard the connection for these exceptions. It will be # replaced during the next _get_conn() call. clean_exit = False if isinstance(e, (BaseSSLError, CertificateError)): e = SSLError(e) elif isinstance(e, (SocketError, NewConnectionError)) and self.proxy: e = ProxyError("Cannot connect to proxy.", e) elif isinstance(e, (SocketError, HTTPException)): e = ProtocolError("Connection aborted.", e) > retries = retries.increment( method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:755: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = Retry(total=0, connect=None, read=False, redirect=None, status=None) method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' response = None error = NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known') _pool = _stacktrace = def increment( self, method=None, url=None, response=None, error=None, _pool=None, _stacktrace=None, ): """Return a new Retry object with incremented retry counters. :param response: A response object, or None, if the server did not return a response. :type response: :class:`~urllib3.response.HTTPResponse` :param Exception error: An error encountered during the request, or None if the response was received successfully. :return: A new ``Retry`` object. """ if self.total is False and error: # Disabled, indicate to re-raise the error. raise six.reraise(type(error), error, _stacktrace) total = self.total if total is not None: total -= 1 connect = self.connect read = self.read redirect = self.redirect status_count = self.status other = self.other cause = "unknown" status = None redirect_location = None if error and self._is_connection_error(error): # Connect retry? if connect is False: raise six.reraise(type(error), error, _stacktrace) elif connect is not None: connect -= 1 elif error and self._is_read_error(error): # Read retry? if read is False or not self._is_method_retryable(method): raise six.reraise(type(error), error, _stacktrace) elif read is not None: read -= 1 elif error: # Other retry? if other is not None: other -= 1 elif response and response.get_redirect_location(): # Redirect retry? if redirect is not None: redirect -= 1 cause = "too many redirects" redirect_location = response.get_redirect_location() status = response.status else: # Incrementing because of a server error like a 500 in # status_forcelist and the given method is in the allowed_methods cause = ResponseError.GENERIC_ERROR if response and response.status: if status_count is not None: status_count -= 1 cause = ResponseError.SPECIFIC_ERROR.format(status_code=response.status) status = response.status history = self.history + ( RequestHistory(method, url, error, status, redirect_location), ) new_retry = self.new( total=total, connect=connect, read=read, redirect=redirect, status=status_count, other=other, history=history, ) if new_retry.is_exhausted(): > raise MaxRetryError(_pool, url, error or ResponseError(cause)) E urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/retry.py:574: MaxRetryError During handling of the above exception, another exception occurred: client = > def test_non_existing_simulation_ui_file(client): > r = client.get('/simulation_ui_file/137') tests/test_api.py:200: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1029: in get return self.open(*args, **kw) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/testing.py:222: in open return Client.open( ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:993: in open response = self.run_wsgi_app(environ.copy(), buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:884: in run_wsgi_app rv = run_wsgi_app(self.application, environ, buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1119: in run_wsgi_app app_rv = app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2463: in __call__ return self.wsgi_app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2449: in wsgi_app response = self.handle_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1866: in handle_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2446: in wsgi_app response = self.full_dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1951: in full_dispatch_request rv = self.handle_user_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1820: in handle_user_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1949: in full_dispatch_request rv = self.dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1935: in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) app/main.py:1433: in simulation_ui_file results = process_results(dataset_search(create_pennsieve_identifier_query(identifier))) app/main.py:690: in dataset_search response = requests.post(f'{Config.SCI_CRUNCH_HOST}/_search', ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:119: in post return request('post', url, data=data, json=json, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:61: in request return session.request(method=method, url=url, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:542: in request resp = self.send(prep, **send_kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:655: in send r = adapter.send(request, **kwargs) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) # Send the request. else: if hasattr(conn, 'proxy_pool'): conn = conn.proxy_pool low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT) try: low_conn.putrequest(request.method, url, skip_accept_encoding=True) for header, value in request.headers.items(): low_conn.putheader(header, value) low_conn.endheaders() for i in request.body: low_conn.send(hex(len(i))[2:].encode('utf-8')) low_conn.send(b'\r\n') low_conn.send(i) low_conn.send(b'\r\n') low_conn.send(b'0\r\n\r\n') # Receive the response from the server try: # For Python 2.7, use buffering of HTTP responses r = low_conn.getresponse(buffering=True) except TypeError: # For compatibility with Python 3.3+ r = low_conn.getresponse() resp = HTTPResponse.from_httplib( r, pool=conn, connection=low_conn, preload_content=False, decode_content=False ) except: # If we hit any problems here, clean up the connection. # Then, reraise so that we can handle the actual exception. low_conn.close() raise except (ProtocolError, socket.error) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) > raise ConnectionError(e, request=request) E requests.exceptions.ConnectionError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:516: ConnectionError ____________________ test_simulation_ui_file_old_s3_bucket _____________________ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: > conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:169: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ address = ('scicrunch.org', 443), timeout = None, source_address = None socket_options = [(6, 1, 1)] def create_connection( address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, source_address=None, socket_options=None, ): """Connect to *address* and return the socket object. Convenience function. Connect to *address* (a 2-tuple ``(host, port)``) and return the socket object. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setting returned by :func:`socket.getdefaulttimeout` is used. If *source_address* is set it must be a tuple of (host, port) for the socket to bind as a source address before making the connection. An host of '' or port 0 tells the OS to use the default. """ host, port = address if host.startswith("["): host = host.strip("[]") err = None # Using the value from allowed_gai_family() in the context of getaddrinfo lets # us select whether to work with IPv4 DNS records, IPv6 records, or both. # The original create_connection function always returns all records. family = allowed_gai_family() try: host.encode("idna") except UnicodeError: return six.raise_from( LocationParseError(u"'%s', label empty or too long" % host), None ) > for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/connection.py:73: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ host = 'scicrunch.org', port = 443, family = type = , proto = 0, flags = 0 def getaddrinfo(host, port, family=0, type=0, proto=0, flags=0): """Resolve host and port into list of address info entries. Translate the host/port argument into a sequence of 5-tuples that contain all the necessary arguments for creating a socket connected to that service. host is a domain name, a string representation of an IPv4/v6 address or None. port is a string service name such as 'http', a numeric port number or None. By passing None as the value of host and port, you can pass NULL to the underlying C API. The family, type and proto arguments can be optionally specified in order to narrow the list of addresses returned. Passing zero as a value for each of these arguments selects the full range of results. """ # We override this function since we want to translate the numeric family # and socket type values to enum constants. addrlist = [] > for res in _socket.getaddrinfo(host, port, family, type, proto, flags): E socket.gaierror: [Errno -2] Name or service not known /usr/lib/python3.9/socket.py:966: gaierror During handling of the above exception, another exception occurred: self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "135"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. > httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:699: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' timeout = Timeout(connect=None, read=None, total=None), chunked = False httplib_request_kw = {'body': b'{"query": {"term": {"pennsieve.identifier.aggregate": "135"}}}', 'headers': {'User-Agent': 'python-requests...ip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'}} timeout_obj = Timeout(connect=None, read=None, total=None) def _make_request( self, conn, method, url, timeout=_Default, chunked=False, **httplib_request_kw ): """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param timeout: Socket timeout in seconds for the request. This can be a float or integer, which will set the same timeout value for the socket connect and the socket read, or an instance of :class:`urllib3.util.Timeout`, which gives you more fine-grained control over your timeouts. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = timeout_obj.connect_timeout # Trigger any extra validation we need to do. try: > self._validate_conn(conn) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:382: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = def _validate_conn(self, conn): """ Called right before a request is made, after the socket is created. """ super(HTTPSConnectionPool, self)._validate_conn(conn) # Force connect early to allow us to validate the connection. if not getattr(conn, "sock", None): # AppEngine might not have `.sock` > conn.connect() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:1010: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def connect(self): # Add certificate verification > conn = self._new_conn() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:353: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) except SocketTimeout: raise ConnectTimeoutError( self, "Connection to %s timed out. (connect timeout=%s)" % (self.host, self.timeout), ) except SocketError as e: > raise NewConnectionError( self, "Failed to establish a new connection: %s" % e ) E urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -2] Name or service not known ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:181: NewConnectionError During handling of the above exception, another exception occurred: self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:439: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "135"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) # If we're going to release the connection in ``finally:``, then # the response doesn't need to know about the connection. Otherwise # it will also try to release it and we'll have a double-release # mess. response_conn = conn if not release_conn else None # Pass method to Response for length checking response_kw["request_method"] = method # Import httplib's response into our own wrapper object response = self.ResponseCls.from_httplib( httplib_response, pool=self, connection=response_conn, retries=retries, **response_kw ) # Everything went great! clean_exit = True except EmptyPoolError: # Didn't get a connection from the pool, no need to clean up clean_exit = True release_this_conn = False raise except ( TimeoutError, HTTPException, SocketError, ProtocolError, BaseSSLError, SSLError, CertificateError, ) as e: # Discard the connection for these exceptions. It will be # replaced during the next _get_conn() call. clean_exit = False if isinstance(e, (BaseSSLError, CertificateError)): e = SSLError(e) elif isinstance(e, (SocketError, NewConnectionError)) and self.proxy: e = ProxyError("Cannot connect to proxy.", e) elif isinstance(e, (SocketError, HTTPException)): e = ProtocolError("Connection aborted.", e) > retries = retries.increment( method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:755: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = Retry(total=0, connect=None, read=False, redirect=None, status=None) method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' response = None error = NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known') _pool = _stacktrace = def increment( self, method=None, url=None, response=None, error=None, _pool=None, _stacktrace=None, ): """Return a new Retry object with incremented retry counters. :param response: A response object, or None, if the server did not return a response. :type response: :class:`~urllib3.response.HTTPResponse` :param Exception error: An error encountered during the request, or None if the response was received successfully. :return: A new ``Retry`` object. """ if self.total is False and error: # Disabled, indicate to re-raise the error. raise six.reraise(type(error), error, _stacktrace) total = self.total if total is not None: total -= 1 connect = self.connect read = self.read redirect = self.redirect status_count = self.status other = self.other cause = "unknown" status = None redirect_location = None if error and self._is_connection_error(error): # Connect retry? if connect is False: raise six.reraise(type(error), error, _stacktrace) elif connect is not None: connect -= 1 elif error and self._is_read_error(error): # Read retry? if read is False or not self._is_method_retryable(method): raise six.reraise(type(error), error, _stacktrace) elif read is not None: read -= 1 elif error: # Other retry? if other is not None: other -= 1 elif response and response.get_redirect_location(): # Redirect retry? if redirect is not None: redirect -= 1 cause = "too many redirects" redirect_location = response.get_redirect_location() status = response.status else: # Incrementing because of a server error like a 500 in # status_forcelist and the given method is in the allowed_methods cause = ResponseError.GENERIC_ERROR if response and response.status: if status_count is not None: status_count -= 1 cause = ResponseError.SPECIFIC_ERROR.format(status_code=response.status) status = response.status history = self.history + ( RequestHistory(method, url, error, status, redirect_location), ) new_retry = self.new( total=total, connect=connect, read=read, redirect=redirect, status=status_count, other=other, history=history, ) if new_retry.is_exhausted(): > raise MaxRetryError(_pool, url, error or ResponseError(cause)) E urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/retry.py:574: MaxRetryError During handling of the above exception, another exception occurred: client = > def test_simulation_ui_file_old_s3_bucket(client): > r = client.get('/simulation_ui_file/135') tests/test_api.py:205: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1029: in get return self.open(*args, **kw) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/testing.py:222: in open return Client.open( ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:993: in open response = self.run_wsgi_app(environ.copy(), buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:884: in run_wsgi_app rv = run_wsgi_app(self.application, environ, buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1119: in run_wsgi_app app_rv = app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2463: in __call__ return self.wsgi_app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2449: in wsgi_app response = self.handle_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1866: in handle_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2446: in wsgi_app response = self.full_dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1951: in full_dispatch_request rv = self.handle_user_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1820: in handle_user_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1949: in full_dispatch_request rv = self.dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1935: in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) app/main.py:1433: in simulation_ui_file results = process_results(dataset_search(create_pennsieve_identifier_query(identifier))) app/main.py:690: in dataset_search response = requests.post(f'{Config.SCI_CRUNCH_HOST}/_search', ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:119: in post return request('post', url, data=data, json=json, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:61: in request return session.request(method=method, url=url, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:542: in request resp = self.send(prep, **send_kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:655: in send r = adapter.send(request, **kwargs) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) # Send the request. else: if hasattr(conn, 'proxy_pool'): conn = conn.proxy_pool low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT) try: low_conn.putrequest(request.method, url, skip_accept_encoding=True) for header, value in request.headers.items(): low_conn.putheader(header, value) low_conn.endheaders() for i in request.body: low_conn.send(hex(len(i))[2:].encode('utf-8')) low_conn.send(b'\r\n') low_conn.send(i) low_conn.send(b'\r\n') low_conn.send(b'0\r\n\r\n') # Receive the response from the server try: # For Python 2.7, use buffering of HTTP responses r = low_conn.getresponse(buffering=True) except TypeError: # For compatibility with Python 3.3+ r = low_conn.getresponse() resp = HTTPResponse.from_httplib( r, pool=conn, connection=low_conn, preload_content=False, decode_content=False ) except: # If we hit any problems here, clean up the connection. # Then, reraise so that we can handle the actual exception. low_conn.close() raise except (ProtocolError, socket.error) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) > raise ConnectionError(e, request=request) E requests.exceptions.ConnectionError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:516: ConnectionError ____________________ test_simulation_ui_file_new_s3_bucket _____________________ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: > conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:169: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ address = ('scicrunch.org', 443), timeout = None, source_address = None socket_options = [(6, 1, 1)] def create_connection( address, timeout=socket._GLOBAL_DEFAULT_TIMEOUT, source_address=None, socket_options=None, ): """Connect to *address* and return the socket object. Convenience function. Connect to *address* (a 2-tuple ``(host, port)``) and return the socket object. Passing the optional *timeout* parameter will set the timeout on the socket instance before attempting to connect. If no *timeout* is supplied, the global default timeout setting returned by :func:`socket.getdefaulttimeout` is used. If *source_address* is set it must be a tuple of (host, port) for the socket to bind as a source address before making the connection. An host of '' or port 0 tells the OS to use the default. """ host, port = address if host.startswith("["): host = host.strip("[]") err = None # Using the value from allowed_gai_family() in the context of getaddrinfo lets # us select whether to work with IPv4 DNS records, IPv6 records, or both. # The original create_connection function always returns all records. family = allowed_gai_family() try: host.encode("idna") except UnicodeError: return six.raise_from( LocationParseError(u"'%s', label empty or too long" % host), None ) > for res in socket.getaddrinfo(host, port, family, socket.SOCK_STREAM): ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/connection.py:73: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ host = 'scicrunch.org', port = 443, family = type = , proto = 0, flags = 0 def getaddrinfo(host, port, family=0, type=0, proto=0, flags=0): """Resolve host and port into list of address info entries. Translate the host/port argument into a sequence of 5-tuples that contain all the necessary arguments for creating a socket connected to that service. host is a domain name, a string representation of an IPv4/v6 address or None. port is a string service name such as 'http', a numeric port number or None. By passing None as the value of host and port, you can pass NULL to the underlying C API. The family, type and proto arguments can be optionally specified in order to narrow the list of addresses returned. Passing zero as a value for each of these arguments selects the full range of results. """ # We override this function since we want to translate the numeric family # and socket type values to enum constants. addrlist = [] > for res in _socket.getaddrinfo(host, port, family, type, proto, flags): E socket.gaierror: [Errno -2] Name or service not known /usr/lib/python3.9/socket.py:966: gaierror During handling of the above exception, another exception occurred: self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "308"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. > httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:699: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' timeout = Timeout(connect=None, read=None, total=None), chunked = False httplib_request_kw = {'body': b'{"query": {"term": {"pennsieve.identifier.aggregate": "308"}}}', 'headers': {'User-Agent': 'python-requests...ip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'}} timeout_obj = Timeout(connect=None, read=None, total=None) def _make_request( self, conn, method, url, timeout=_Default, chunked=False, **httplib_request_kw ): """ Perform a request on a given urllib connection object taken from our pool. :param conn: a connection from one of our connection pools :param timeout: Socket timeout in seconds for the request. This can be a float or integer, which will set the same timeout value for the socket connect and the socket read, or an instance of :class:`urllib3.util.Timeout`, which gives you more fine-grained control over your timeouts. """ self.num_requests += 1 timeout_obj = self._get_timeout(timeout) timeout_obj.start_connect() conn.timeout = timeout_obj.connect_timeout # Trigger any extra validation we need to do. try: > self._validate_conn(conn) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:382: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = conn = def _validate_conn(self, conn): """ Called right before a request is made, after the socket is created. """ super(HTTPSConnectionPool, self)._validate_conn(conn) # Force connect early to allow us to validate the connection. if not getattr(conn, "sock", None): # AppEngine might not have `.sock` > conn.connect() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:1010: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def connect(self): # Add certificate verification > conn = self._new_conn() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:353: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = def _new_conn(self): """Establish a socket connection and set nodelay settings on it. :return: New socket connection. """ extra_kw = {} if self.source_address: extra_kw["source_address"] = self.source_address if self.socket_options: extra_kw["socket_options"] = self.socket_options try: conn = connection.create_connection( (self._dns_host, self.port), self.timeout, **extra_kw ) except SocketTimeout: raise ConnectTimeoutError( self, "Connection to %s timed out. (connect timeout=%s)" % (self.host, self.timeout), ) except SocketError as e: > raise NewConnectionError( self, "Failed to establish a new connection: %s" % e ) E urllib3.exceptions.NewConnectionError: : Failed to establish a new connection: [Errno -2] Name or service not known ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connection.py:181: NewConnectionError During handling of the above exception, another exception occurred: self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: > resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:439: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' body = b'{"query": {"term": {"pennsieve.identifier.aggregate": "308"}}}' headers = {'User-Agent': 'python-requests/2.25.1', 'Accept-Encoding': 'gzip, deflate', 'Accept': '*/*', 'Connection': 'keep-alive', 'Content-Length': '62', 'Content-Type': 'application/json'} retries = Retry(total=0, connect=None, read=False, redirect=None, status=None) redirect = False, assert_same_host = False timeout = Timeout(connect=None, read=None, total=None), pool_timeout = None release_conn = False, chunked = False, body_pos = None response_kw = {'decode_content': False, 'preload_content': False} parsed_url = Url(scheme=None, auth=None, host=None, port=None, path='/api/1/elastic/SPARC_PortalDatasets_dev/_search', query='api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf', fragment=None) destination_scheme = None, conn = None, release_this_conn = True http_tunnel_required = False, err = None, clean_exit = False def urlopen( self, method, url, body=None, headers=None, retries=None, redirect=True, assert_same_host=True, timeout=_Default, pool_timeout=None, release_conn=None, chunked=False, body_pos=None, **response_kw ): """ Get a connection from the pool and perform an HTTP request. This is the lowest level call for making a request, so you'll need to specify all the raw details. .. note:: More commonly, it's appropriate to use a convenience method provided by :class:`.RequestMethods`, such as :meth:`request`. .. note:: `release_conn` will only behave as expected if `preload_content=False` because we want to make `preload_content=False` the default behaviour someday soon without breaking backwards compatibility. :param method: HTTP request method (such as GET, POST, PUT, etc.) :param url: The URL to perform the request on. :param body: Data to send in the request body, either :class:`str`, :class:`bytes`, an iterable of :class:`str`/:class:`bytes`, or a file-like object. :param headers: Dictionary of custom headers to send, such as User-Agent, If-None-Match, etc. If None, pool headers are used. If provided, these headers completely replace any pool-specific headers. :param retries: Configure the number of retries to allow before raising a :class:`~urllib3.exceptions.MaxRetryError` exception. Pass ``None`` to retry until you receive a response. Pass a :class:`~urllib3.util.retry.Retry` object for fine-grained control over different types of retries. Pass an integer number to retry connection errors that many times, but no other types of errors. Pass zero to never retry. If ``False``, then retries are disabled and any exception is raised immediately. Also, instead of raising a MaxRetryError on redirects, the redirect response will be returned. :type retries: :class:`~urllib3.util.retry.Retry`, False, or an int. :param redirect: If True, automatically handle redirects (status codes 301, 302, 303, 307, 308). Each redirect counts as a retry. Disabling retries will disable redirect, too. :param assert_same_host: If ``True``, will make sure that the host of the pool requests is consistent else will raise HostChangedError. When ``False``, you can use the pool on an HTTP proxy and request foreign hosts. :param timeout: If specified, overrides the default timeout for this one request. It may be a float (in seconds) or an instance of :class:`urllib3.util.Timeout`. :param pool_timeout: If set and the pool is set to block=True, then this method will block for ``pool_timeout`` seconds and raise EmptyPoolError if no connection is available within the time period. :param release_conn: If False, then the urlopen call will not release the connection back into the pool once a response is received (but will release if you read the entire contents of the response such as when `preload_content=True`). This is useful if you're not preloading the response's content immediately. You will need to call ``r.release_conn()`` on the response ``r`` to return the connection back into the pool. If None, it takes the value of ``response_kw.get('preload_content', True)``. :param chunked: If True, urllib3 will send the body using chunked transfer encoding. Otherwise, urllib3 will send the body using the standard content-length form. Defaults to False. :param int body_pos: Position to seek to in file-like body in the event of a retry or redirect. Typically this won't need to be set because urllib3 will auto-populate the value when needed. :param \\**response_kw: Additional parameters are passed to :meth:`urllib3.response.HTTPResponse.from_httplib` """ parsed_url = parse_url(url) destination_scheme = parsed_url.scheme if headers is None: headers = self.headers if not isinstance(retries, Retry): retries = Retry.from_int(retries, redirect=redirect, default=self.retries) if release_conn is None: release_conn = response_kw.get("preload_content", True) # Check host if assert_same_host and not self.is_same_host(url): raise HostChangedError(self, url, retries) # Ensure that the URL we're connecting to is properly encoded if url.startswith("/"): url = six.ensure_str(_encode_target(url)) else: url = six.ensure_str(parsed_url.url) conn = None # Track whether `conn` needs to be released before # returning/raising/recursing. Update this variable if necessary, and # leave `release_conn` constant throughout the function. That way, if # the function recurses, the original value of `release_conn` will be # passed down into the recursive call, and its value will be respected. # # See issue #651 [1] for details. # # [1] release_this_conn = release_conn http_tunnel_required = connection_requires_http_tunnel( self.proxy, self.proxy_config, destination_scheme ) # Merge the proxy headers. Only done when not using HTTP CONNECT. We # have to copy the headers dict so we can safely change it without those # changes being reflected in anyone else's copy. if not http_tunnel_required: headers = headers.copy() headers.update(self.proxy_headers) # Must keep the exception bound to a separate variable or else Python 3 # complains about UnboundLocalError. err = None # Keep track of whether we cleanly exited the except block. This # ensures we do proper cleanup in finally. clean_exit = False # Rewind body position, if needed. Record current position # for future rewinds in the event of a redirect/retry. body_pos = set_file_position(body, body_pos) try: # Request a connection from the queue. timeout_obj = self._get_timeout(timeout) conn = self._get_conn(timeout=pool_timeout) conn.timeout = timeout_obj.connect_timeout is_new_proxy_conn = self.proxy is not None and not getattr( conn, "sock", None ) if is_new_proxy_conn and http_tunnel_required: self._prepare_proxy(conn) # Make the request on the httplib connection object. httplib_response = self._make_request( conn, method, url, timeout=timeout_obj, body=body, headers=headers, chunked=chunked, ) # If we're going to release the connection in ``finally:``, then # the response doesn't need to know about the connection. Otherwise # it will also try to release it and we'll have a double-release # mess. response_conn = conn if not release_conn else None # Pass method to Response for length checking response_kw["request_method"] = method # Import httplib's response into our own wrapper object response = self.ResponseCls.from_httplib( httplib_response, pool=self, connection=response_conn, retries=retries, **response_kw ) # Everything went great! clean_exit = True except EmptyPoolError: # Didn't get a connection from the pool, no need to clean up clean_exit = True release_this_conn = False raise except ( TimeoutError, HTTPException, SocketError, ProtocolError, BaseSSLError, SSLError, CertificateError, ) as e: # Discard the connection for these exceptions. It will be # replaced during the next _get_conn() call. clean_exit = False if isinstance(e, (BaseSSLError, CertificateError)): e = SSLError(e) elif isinstance(e, (SocketError, NewConnectionError)) and self.proxy: e = ProxyError("Cannot connect to proxy.", e) elif isinstance(e, (SocketError, HTTPException)): e = ProtocolError("Connection aborted.", e) > retries = retries.increment( method, url, error=e, _pool=self, _stacktrace=sys.exc_info()[2] ) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/connectionpool.py:755: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = Retry(total=0, connect=None, read=False, redirect=None, status=None) method = 'POST' url = '/api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf' response = None error = NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known') _pool = _stacktrace = def increment( self, method=None, url=None, response=None, error=None, _pool=None, _stacktrace=None, ): """Return a new Retry object with incremented retry counters. :param response: A response object, or None, if the server did not return a response. :type response: :class:`~urllib3.response.HTTPResponse` :param Exception error: An error encountered during the request, or None if the response was received successfully. :return: A new ``Retry`` object. """ if self.total is False and error: # Disabled, indicate to re-raise the error. raise six.reraise(type(error), error, _stacktrace) total = self.total if total is not None: total -= 1 connect = self.connect read = self.read redirect = self.redirect status_count = self.status other = self.other cause = "unknown" status = None redirect_location = None if error and self._is_connection_error(error): # Connect retry? if connect is False: raise six.reraise(type(error), error, _stacktrace) elif connect is not None: connect -= 1 elif error and self._is_read_error(error): # Read retry? if read is False or not self._is_method_retryable(method): raise six.reraise(type(error), error, _stacktrace) elif read is not None: read -= 1 elif error: # Other retry? if other is not None: other -= 1 elif response and response.get_redirect_location(): # Redirect retry? if redirect is not None: redirect -= 1 cause = "too many redirects" redirect_location = response.get_redirect_location() status = response.status else: # Incrementing because of a server error like a 500 in # status_forcelist and the given method is in the allowed_methods cause = ResponseError.GENERIC_ERROR if response and response.status: if status_count is not None: status_count -= 1 cause = ResponseError.SPECIFIC_ERROR.format(status_code=response.status) status = response.status history = self.history + ( RequestHistory(method, url, error, status, redirect_location), ) new_retry = self.new( total=total, connect=connect, read=read, redirect=redirect, status=status_count, other=other, history=history, ) if new_retry.is_exhausted(): > raise MaxRetryError(_pool, url, error or ResponseError(cause)) E urllib3.exceptions.MaxRetryError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/urllib3/util/retry.py:574: MaxRetryError During handling of the above exception, another exception occurred: client = > def test_simulation_ui_file_new_s3_bucket(client): > r = client.get('/simulation_ui_file/308') tests/test_api.py:211: _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1029: in get return self.open(*args, **kw) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/testing.py:222: in open return Client.open( ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:993: in open response = self.run_wsgi_app(environ.copy(), buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:884: in run_wsgi_app rv = run_wsgi_app(self.application, environ, buffered=buffered) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/werkzeug/test.py:1119: in run_wsgi_app app_rv = app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2463: in __call__ return self.wsgi_app(environ, start_response) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2449: in wsgi_app response = self.handle_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1866: in handle_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:2446: in wsgi_app response = self.full_dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1951: in full_dispatch_request rv = self.handle_user_exception(e) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_cors/extension.py:161: in wrapped_function return cors_after_request(app.make_response(f(*args, **kwargs))) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1820: in handle_user_exception reraise(exc_type, exc_value, tb) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/_compat.py:39: in reraise raise value ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1949: in full_dispatch_request rv = self.dispatch_request() ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask/app.py:1935: in dispatch_request return self.view_functions[rule.endpoint](**req.view_args) app/main.py:1433: in simulation_ui_file results = process_results(dataset_search(create_pennsieve_identifier_query(identifier))) app/main.py:690: in dataset_search response = requests.post(f'{Config.SCI_CRUNCH_HOST}/_search', ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:119: in post return request('post', url, data=data, json=json, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/api.py:61: in request return session.request(method=method, url=url, **kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:542: in request resp = self.send(prep, **send_kwargs) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/sessions.py:655: in send r = adapter.send(request, **kwargs) _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ self = request = , stream = False timeout = Timeout(connect=None, read=None, total=None), verify = True cert = None, proxies = OrderedDict() def send(self, request, stream=False, timeout=None, verify=True, cert=None, proxies=None): """Sends PreparedRequest object. Returns Response object. :param request: The :class:`PreparedRequest ` being sent. :param stream: (optional) Whether to stream the request content. :param timeout: (optional) How long to wait for the server to send data before giving up, as a float, or a :ref:`(connect timeout, read timeout) ` tuple. :type timeout: float or tuple or urllib3 Timeout object :param verify: (optional) Either a boolean, in which case it controls whether we verify the server's TLS certificate, or a string, in which case it must be a path to a CA bundle to use :param cert: (optional) Any user-provided SSL certificate to be trusted. :param proxies: (optional) The proxies dictionary to apply to the request. :rtype: requests.Response """ try: conn = self.get_connection(request.url, proxies) except LocationValueError as e: raise InvalidURL(e, request=request) self.cert_verify(conn, request.url, verify, cert) url = self.request_url(request, proxies) self.add_headers(request, stream=stream, timeout=timeout, verify=verify, cert=cert, proxies=proxies) chunked = not (request.body is None or 'Content-Length' in request.headers) if isinstance(timeout, tuple): try: connect, read = timeout timeout = TimeoutSauce(connect=connect, read=read) except ValueError as e: # this may raise a string formatting error. err = ("Invalid timeout {}. Pass a (connect, read) " "timeout tuple, or a single float to set " "both timeouts to the same value".format(timeout)) raise ValueError(err) elif isinstance(timeout, TimeoutSauce): pass else: timeout = TimeoutSauce(connect=timeout, read=timeout) try: if not chunked: resp = conn.urlopen( method=request.method, url=url, body=request.body, headers=request.headers, redirect=False, assert_same_host=False, preload_content=False, decode_content=False, retries=self.max_retries, timeout=timeout ) # Send the request. else: if hasattr(conn, 'proxy_pool'): conn = conn.proxy_pool low_conn = conn._get_conn(timeout=DEFAULT_POOL_TIMEOUT) try: low_conn.putrequest(request.method, url, skip_accept_encoding=True) for header, value in request.headers.items(): low_conn.putheader(header, value) low_conn.endheaders() for i in request.body: low_conn.send(hex(len(i))[2:].encode('utf-8')) low_conn.send(b'\r\n') low_conn.send(i) low_conn.send(b'\r\n') low_conn.send(b'0\r\n\r\n') # Receive the response from the server try: # For Python 2.7, use buffering of HTTP responses r = low_conn.getresponse(buffering=True) except TypeError: # For compatibility with Python 3.3+ r = low_conn.getresponse() resp = HTTPResponse.from_httplib( r, pool=conn, connection=low_conn, preload_content=False, decode_content=False ) except: # If we hit any problems here, clean up the connection. # Then, reraise so that we can handle the actual exception. low_conn.close() raise except (ProtocolError, socket.error) as err: raise ConnectionError(err, request=request) except MaxRetryError as e: if isinstance(e.reason, ConnectTimeoutError): # TODO: Remove this in 3.0.0: see #2811 if not isinstance(e.reason, NewConnectionError): raise ConnectTimeout(e, request=request) if isinstance(e.reason, ResponseError): raise RetryError(e, request=request) if isinstance(e.reason, _ProxyError): raise ProxyError(e, request=request) if isinstance(e.reason, _SSLError): # This branch is for urllib3 v1.22 and later. raise SSLError(e, request=request) > raise ConnectionError(e, request=request) E requests.exceptions.ConnectionError: HTTPSConnectionPool(host='scicrunch.org', port=443): Max retries exceeded with url: /api/1/elastic/SPARC_PortalDatasets_dev/_search?api_key=xBOrIfnZTvJQtobGo8XHRvThdMYGTxtf (Caused by NewConnectionError(': Failed to establish a new connection: [Errno -2] Name or service not known')) ../../shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/requests/adapters.py:516: ConnectionError __________________________ test_neurolucida_thumbnail __________________________ client = > def test_neurolucida_thumbnail(client): query_string = {'datasetId': 37, 'version': 3, 'path': 'files/derivative/sub-54-5/TJU_3Scan_ratheart54-5_updated_06_11_19_Fiducials.xml'} r = client.get('/thumbnail/neurolucida', query_string=query_string) > assert r.data.decode('utf-8').startswith('iVBORw0KGgoAAAANSUhEUgAAAtAAAAIcCAIAAABQHw4EAAAgAElEQVR4Xuy9P4hjWZbu+zWv4erChVwNAyPjQq') E assert False E + where False = ('iVBORw0KGgoAAAANSUhEUgAAAtAAAAIcCAIAAABQHw4EAAAgAElEQVR4Xuy9P4hjWZbu+zWv4erChVwNAyPjQq') E + where = '\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n'.startswith E + where '\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n' = ('utf-8') E + where = b'\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n'.decode E + where b'\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n' = .data tests/test_thumbnails.py:22: AssertionError ____________________ test_neurolucida_thumbnail_dataset_221 ____________________ client = > def test_neurolucida_thumbnail_dataset_221(client): query_string = {'datasetId': 221, 'version': 3, 'path': 'files/derivative/sub-M168/digital-traces/pCm168_AAV_Z_20x_191211_S3B_lx_IGS.xml'} r = client.get('/thumbnail/neurolucida', query_string=query_string) > assert r.data.decode('utf-8').startswith('iVBORw0KGgoAAAANSUhEUgAAAtAAAAIcCAIAAABQHw4EAAAgAElEQVR4Xuzdd3xV9f348fe569ydm') E assert False E + where False = ('iVBORw0KGgoAAAANSUhEUgAAAtAAAAIcCAIAAABQHw4EAAAgAElEQVR4Xuzdd3xV9f348fe569ydm') E + where = '\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n'.startswith E + where '\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n' = ('utf-8') E + where = b'\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n'.decode E + where b'\n400 Bad Request\n

Bad Request

\n

Unable to make a connection to NEUROLUCIDA_HOST.

\n' = .data tests/test_thumbnails.py:29: AssertionError =============================== warnings summary =============================== /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/apscheduler/__init__.py:1 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/apscheduler/__init__.py:1: DeprecationWarning: pkg_resources is deprecated as an API. See https://setuptools.pypa.io/en/latest/pkg_resources.html from pkg_resources import get_distribution, DistributionNotFound /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/marshmallow/__init__.py:17 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/marshmallow/__init__.py:17: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. __version_info__ = tuple(LooseVersion(__version__).version) /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_marshmallow/__init__.py:34 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/flask_marshmallow/__init__.py:34: DeprecationWarning: distutils Version classes are deprecated. Use packaging.version instead. __version_info__ = tuple(LooseVersion(__version__).version) /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:19 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:19: DeprecationWarning: Call to deprecated create function FileDescriptor(). Note: Create unlinked descriptors is going to go away. Please use get/find descriptors from generated code or query the descriptor_pool. DESCRIPTOR = _descriptor.FileDescriptor( /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:36 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:36: DeprecationWarning: Call to deprecated create function FieldDescriptor(). Note: Create unlinked descriptors is going to go away. Please use get/find descriptors from generated code or query the descriptor_pool. _descriptor.FieldDescriptor( /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:53 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:53: DeprecationWarning: Call to deprecated create function FieldDescriptor(). Note: Create unlinked descriptors is going to go away. Please use get/find descriptors from generated code or query the descriptor_pool. _descriptor.FieldDescriptor( /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:70 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:70: DeprecationWarning: Call to deprecated create function FieldDescriptor(). Note: Create unlinked descriptors is going to go away. Please use get/find descriptors from generated code or query the descriptor_pool. _descriptor.FieldDescriptor( /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:29 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/pennsieve/cache/cache_segment_pb2.py:29: DeprecationWarning: Call to deprecated create function Descriptor(). Note: Create unlinked descriptors is going to go away. Please use get/find descriptors from generated code or query the descriptor_pool. _CACHESEGMENT = _descriptor.Descriptor( /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/nose/importer.py:12 /home/cmiss/Jenkins/shiningpanda/jobs/7c726052/virtualenvs/d41d8cd9/lib/python3.9/site-packages/nose/importer.py:12: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses from imp import find_module, load_module, acquire_lock, release_lock tests/test_health.py::test_request_response /home/cmiss/Jenkins/workspace/SPARC-API-DEV/tests/test_health.py:13: DeprecationWarning: Please use assertEqual instead. assert_equals("healthy", json_response.get("status")) -- Docs: https://docs.pytest.org/en/latest/warnings.html =========================== short test summary info ============================ FAILED tests/test_api.py::test_onto_term_lookup - assert 500 == 200 FAILED tests/test_api.py::test_non_existing_simulation_ui_file - requests.exc... FAILED tests/test_api.py::test_simulation_ui_file_old_s3_bucket - requests.ex... FAILED tests/test_api.py::test_simulation_ui_file_new_s3_bucket - requests.ex... FAILED tests/test_thumbnails.py::test_neurolucida_thumbnail - assert False FAILED tests/test_thumbnails.py::test_neurolucida_thumbnail_dataset_221 - ass... ======= 6 failed, 99 passed, 4 skipped, 10 warnings in 346.71s (0:05:46) ======= Build step 'Virtualenv Builder' marked build as failure [Slack Notifications] found #1038 as previous completed, non-aborted build [Slack Notifications] will send OnEveryFailureNotification because build matches and user preferences allow it Finished: FAILURE