Creating a dictionary with a path name and SHA-256 hash
In your code, you show two ways to create your dictionary, but both are somewhat flawed:


diction will be a list of dictionaries, each holding just one entry
dic2 will get overwritten in each iteration of the loop, and will finally hold only one dictionary, again with only one element.


Instead, try this:

diction = dict([ (fname, hashlib.sha256(open(fname, 'rb').read()).digest())
                 for fname in fnamelst ])


Or shorter, for Python 2.7 or later:

diction = { fname: hashlib.sha256(open(fname, 'rb').read()).digest()
                 for fname in fnamelst }


The first one uses a list comprehension to create a list of key-value tuples, and then uses the dict function to create a single dictionary from that list. The second one does the same, using a dict comprehension.