e3d577b5595af3e1c9a05d3be84dbdf1a7c4aa20,nilearn/datasets/neurovault.py,,_get_batch,#Any#Any#Any#Any#,962
Before Change
try:
encoding = _get_encoding(resp)
content = resp.read()
batch = json.loads(content.decode(encoding))
except(URLError, ValueError):
_print_if("Could not decypher batch from {0}".format(query),
_ERROR, verbose, with_traceback=True)
raise
After Change
session = _requests_session()
req = requests.Request(
method="GET", url=query, headers={"Connection": "Keep-Alive"})
prepped = session.prepare_request(req)
_print_if("{0}getting new batch: {1}".format(
prefix_msg, query), _DEBUG, verbose)
try:
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: nilearn/nilearn
Commit Name: e3d577b5595af3e1c9a05d3be84dbdf1a7c4aa20
Time: 2020-07-29
Author: jerome@dockes.org
File Name: nilearn/datasets/neurovault.py
Class Name:
Method Name: _get_batch
Project Name: commonsense/conceptnet5
Commit Name: db4b9f4d50af9e83733fc301c32e85cbe6d9c812
Time: 2014-02-25
Author: rob@luminoso.com
File Name: conceptnet5/builders/json_to_solr.py
Class Name:
Method Name: convert_to_solr
Project Name: cesium-ml/cesium
Commit Name: 5b5fb4c657f0cdf4fe404aa9daaf99aca83d01cf
Time: 2016-02-24
Author: brettnaul@gmail.com
File Name: mltsp/tests/test_flask_app.py
Class Name: FlaskAppTestCase
Method Name: test_upload_features_form