twonds / punjab

BOSH connection manager
MIT License
183 stars 49 forks source link

Work around SRV connect issue with Twisted 12.3.0. #27

Closed ralphm closed 11 years ago

ralphm commented 11 years ago

Refs: twonds/punjab#26.

twonds commented 11 years ago

Thanks ralph, wish it had a test but punjab needs a lot of love in that department.

cvogler commented 11 years ago

I still get this problem with Python 2.7 and the latest master that has this patch integrated. Upon looking at the code, I see that "domain" is recoded as ascii only after it already has been passed to the base class. That doesn't look right to me - it seems that the isinstance check and encoding as ascii needs to come before calling the base class's init method.