5765f471197edbf64a57dd2628dcd3051c7ea46c,gyoithon.py,,,#,193
Before Change
response = ""
try:
with urlopen(target_url) as furl:
response = str(furl.info()).rstrip()
response += "\n\n" + furl.read().decode("utf-8")
with codecs.open(os.path.join(full_path + "/gyoithon/", log_file), "a", "utf-8") as fout:
fout.write(response)
After Change
// Get HTTP responses.
log_file = "get_" + ip_list[idx] + "_" + str(port_list[idx]) + "_ip.log"
con = urllib3.PoolManager()
for scheme in ["http://", "https://"]:
target_url = scheme + ip_list[idx] + ":" + port_list[idx] + path_list[idx]
response = ""
try:
// Get HTTP headers and body.
res = con.request("GET", target_url)
headers = dict(res.headers)
for header in headers.keys():
response += header + ": " + headers[header].replace(""", "") + "\n"
response += "\n" + res.data.decode("utf-8") + "\n"
with codecs.open(os.path.join(full_path + "/gyoithon/", log_file), "a", "utf-8") as fout:
fout.write(response)
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 12
Instances
Project Name: gyoisamurai/GyoiThon
Commit Name: 5765f471197edbf64a57dd2628dcd3051c7ea46c
Time: 2018-06-04
Author: gyoiler3@gmail.com
File Name: gyoithon.py
Class Name:
Method Name:
Project Name: NifTK/NiftyNet
Commit Name: 61a0663a45beb2e59f6a549c51d55940c80734e3
Time: 2018-03-05
Author: rmaplue@ucl.ac.uk
File Name: niftynet/io/image_as_nibabel.py
Class Name:
Method Name:
Project Name: gyoisamurai/GyoiThon
Commit Name: 4f53bca9b044b20bc4aa8b7719bbbb2984623b3a
Time: 2018-06-04
Author: gyoiler3@gmail.com
File Name: classifier4gyoithon/GyoiClassifier.py
Class Name:
Method Name:
Project Name: gyoisamurai/GyoiThon
Commit Name: 5765f471197edbf64a57dd2628dcd3051c7ea46c
Time: 2018-06-04
Author: gyoiler3@gmail.com
File Name: gyoithon.py
Class Name:
Method Name: