Did I find the right examples for you? yes no

All Samples(5)  |  Call(3)  |  Derive(0)  |  Import(2)

        def md5sum(filename):
    f = open(filename)
    md5 = hashlib.md5()
    while True:
        data = f.read(8192)
        if not data:
            break
        md5.update(data)
    return md5.hexdigest()
        


src/x/m/xmppserver-HEAD/kontalk/xmppserver/storage.py   xmppserver(Download)
        # this is intentionally done to verify that the file is not corruputed on disk
        # TODO this should be async
        md5sum = util.md5sum(filename)
 
        # write metadata file (avoid using ConfigParser, it's a simple file)

src/b/e/benchbase-1.1.0/benchbase/bencher.py   benchbase(Download)
import datetime
from model import INSERT_QUERY, SCHEMAS
from util import md5sum, mygzip, truncate, str2id
 
 
    def doImport(self, filename):
        md5 = md5sum(filename)
        if self.alreadyImported(md5, filename):
            return
        bid = self.registerBench(md5, filename)

src/b/e/benchbase-HEAD/benchbase/bencher.py   benchbase(Download)
import datetime
from model import INSERT_QUERY, SCHEMAS
from util import md5sum, mygzip, truncate, str2id
 
 
    def doImport(self, filename):
        md5 = md5sum(filename)
        if self.alreadyImported(md5, filename):
            return
        bid = self.registerBench(md5, filename)