
import urllib2


class ArchiverWrapper(object):
    def restart_archiver(self):
        # Set to ignore proxy for localhost
        proxy_handler = urllib2.ProxyHandler({})
        opener = urllib2.build_opener(proxy_handler)
        urllib2.install_opener(opener)
        urllib2.urlopen("http://localhost:4813/restart")


import urllib2


class ArchiverWrapper(object):
    def restart_archiver(self):
        # Set to ignore proxy for localhost
        proxy_handler = urllib2.ProxyHandler({})
        opener = urllib2.build_opener(proxy_handler)
        urllib2.install_opener(opener)
        res = urllib2.urlopen("http://localhost:4813/restart")
        d = res.read()

Read returned page, just to make sure
Read returned page, just to make sure

  
  import urllib2
  
  
  class ArchiverWrapper(object):
      def restart_archiver(self):
          # Set to ignore proxy for localhost
          proxy_handler = urllib2.ProxyHandler({})
          opener = urllib2.build_opener(proxy_handler)
          urllib2.install_opener(opener)
-         urllib2.urlopen("http://localhost:4813/restart")
+         res = urllib2.urlopen("http://localhost:4813/restart")
+         d = res.read()
  
Read returned page, just to make sure
## Code Before:

import urllib2


class ArchiverWrapper(object):
    def restart_archiver(self):
        # Set to ignore proxy for localhost
        proxy_handler = urllib2.ProxyHandler({})
        opener = urllib2.build_opener(proxy_handler)
        urllib2.install_opener(opener)
        urllib2.urlopen("http://localhost:4813/restart")

## Instruction:
Read returned page, just to make sure
## Code After:

import urllib2


class ArchiverWrapper(object):
    def restart_archiver(self):
        # Set to ignore proxy for localhost
        proxy_handler = urllib2.ProxyHandler({})
        opener = urllib2.build_opener(proxy_handler)
        urllib2.install_opener(opener)
        res = urllib2.urlopen("http://localhost:4813/restart")
        d = res.read()
