Changes between and of Initial VersionVersion 2Ticket #5789


Ignore:
Timestamp:
07/17/2012 11:54:35 AM (2 years ago)
Author:
thijs
Comment:

Meh, not sure why I didnt notice that before. So in Python 2.7 it's in the old place and Python 3 moves it to the collections module. I suggest to add a twisted.python.compat version in that case like we did with execfile.

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #5789

    • Property Summary changed from Replace UserDict imports with collections version to Replace usage of UserDict with twisted.python.compat version
  • Ticket #5789 – Description

    initial v2  
    1 `UserDict` was moved to the [http://docs.python.org/py3k/library/collections.html#collections.UserDict collections] module in Python 2.6/3.x. The import for `UserDict` needs to be adjusted or it will throw errors in python 3. 
     1`UserDict` was moved to the [http://docs.python.org/py3k/library/collections.html#collections.UserDict collections] module in Python 3.x. We can add a twisted.python.compat version, like we did with `execfile` or it will throw errors in python 3. 
    22 
    33{{{ 
     
    1414}}} 
    1515 
    16 And it looks like `DictMixin` is gone so this cannot simply be fixed by adjusting the import.. 
     16And it looks like `DictMixin` is gone but you should be able to use `MutableMapping` with some adjustment. 
    1717 
    1818{{{