I want to check domain ownership by reading domain's TXT records. But it seem all library handle that job were written in python 2.x
I have used:
dns.resolver
domcheck
but all of them fail with error: 'dict' object has no attribute 'iteritems'
Can I do that in Python 3.x ?
Asked
Active
Viewed 90 times
0

Son Tran
- 1,498
- 4
- 18
- 32
-
1You could fork the library and modify it for Python 3.x (e.g. by switching to `.items` instead of `.iteritems`). – jonrsharpe Sep 08 '15 at 11:29
-
Unfortunately what @jonrsharpe seems to be the only option, because you cannot monkey-patch built-in data-types. You would have to fix the `dict` implementation, which is not possible. See also http://stackoverflow.com/questions/192649/can-you-monkey-patch-methods-on-core-types-in-python/192857#192857 Perhaps this is the time to fork the project, create a Python 3.x version and contribute your changes to the original project. :) – dotcs Sep 08 '15 at 11:43