Newbie to Python, so this may seem silly.
I have two dicts:
default = {\'a\': \'alpha\', \'b\': \'beta\', \'g\': \'Gamma\'} user = {\'a\': \'NewAlpha\',
With the update() method, and some generator expression:
update()
D.update((k, v) for k, v in user.iteritems() if v is not None)
result = default.copy() result.update((k, v) for k, v in user.iteritems() if v is not None)