This change in difference is caused by https://github.com/python/cpython/commit/e036ef8fa29f27d57fe9f8cef8d931d4122d8223
The old code checked for duplicate arguments by essentially running `set().intersection(d)` and since `set().intersection(['a', 'a'])` is the empty set, it doesn't register as a duplicated argument. The newer code iterates over the keys in order to merge the dictionaries.
Note however that 3.5 is now is in security only mode: https://devguide.python.org/#branchstatus so its unlikely this behavior will be back-ported. |