~ubuntu-core-dev/ubuntu/xenial/ubuntu-release-upgrader/xenial

« back to all changes in this revision

Viewing changes to DistUpgrade/DistUpgradeFetcherCore.py

  • Committer: Dimitri John Ledkov
  • Date: 2015-01-20 22:30:06 UTC
  • mto: This revision was merged to the branch mainline in revision 2859.
  • Revision ID: dimitri.j.ledkov@intel.com-20150120223006-ba30fbqtp4x2n0og
Fix resource warnings & logging.warn deprecation warning.

Show diffs side-by-side

added added

removed removed

Lines of Context:
246
246
            af2
247
247
            result = fetcher.run()
248
248
            if result != fetcher.RESULT_CONTINUE:
249
 
                logging.warn("fetch result != continue (%s)" % result)
 
249
                logging.warning("fetch result != continue (%s)" % result)
250
250
                return False
251
251
            # check that both files are really there and non-null
252
252
            for f in [os.path.basename(self.new_dist.upgradeToolSig),
253
253
                      os.path.basename(self.new_dist.upgradeTool)]:
254
254
                if not (os.path.exists(f) and os.path.getsize(f) > 0):
255
 
                    logging.warn("file '%s' missing" % f)
 
255
                    logging.warning("file '%s' missing" % f)
256
256
                    return False
257
257
            return True
258
258
        return False